|
Ah...... I knew it would be something really annoyingly simple. Thank you both very much for the help. You have no idea the hours of frustration that saved me.
Thanks again,
Charles
|
|
|
|
|
hi guys,
i'm having one word document(2003) with many pages [eg.. 100 pages],
each page has different headers informations
and footers information, and different body text.
now what i want is,
To read the content of each page and write it to another file [Chk1.doc].
one more thing while writing to a file,
while writing in another file, i don't want header and footer instead i want the every page header information to be written at the top every page and footer information to be written at the end of every page and body of the page in the middle.
i want to do this task in vb.net
Pls help me.
Thnks,
regards,
P.Prakash
|
|
|
|
|
I haven't done any Office Interop work in the last 10 years, so I can't tell you exactly how to do it. But, the Visual Studio Tools for Office[^] may be of some help to you.
You may also want to Google for "vb.net retrieve text from Word document" that may give you some close examples.
|
|
|
|
|
|
Please help!!
I need to send email to multiple users within a SQL database. How can I create an email class to send mail using SMTP and get all the users from the database to send it to??
I have never worked with VB and would appreciate the assistance...
Thank you in advance
Illegal Operation
Making Computer Software Talk
|
|
|
|
|
Google results for "send eail from vb.net[^]". Depending on the version of VB.nET you're using, the code can change. You either looking for the System.Web.Mail namespace (.NET 1.x) or the System.Net.Mail namespace (.NET 2.0 and above).
There's a bunch of ways to get data out of SQL server. Google for "get data from sql server in vb.net[^]" for some of the various methods.
|
|
|
|
|
Salam,
I've added a button in my form, from which i close the selected tabpage of my tabcontrol , but in some applications i've seen that there are some tabcontrols that comes with a built in X closing button on the right hand side, just like the one in the VS.Net, also i've realized that the tabpages are not normal, they have a good crazy design, i don't know if this is a separate control or an advaned tabcontrol .
Would you help me please ??
Thank you very much
try to be good if you can't be the best
|
|
|
|
|
I don't really know what you're question is, but I'll take a guess at what you're getting at.
This functionality isn't in the standard TabControl in the toolbox. This is either a customized control or a control in a commercially available library.
|
|
|
|
|
Hey,
Just thougt I'd post a message if anyone was wondering about this project. I deleted it late December 2007, mainly because it was taking too much of my time - in hindsight it was a silly thing todo (as well as pretty selfish), but the code is back online now.
It's still a half baked project (I was going to wait until I had finished it, but since it's an open source project, getting opinions on the software before it's finished is one of the major aspects of open source development!) and I still need to write heaps of documentation for it.
It's got the SQL databases as well this time, so you can run it on either SQL Server or Access (the MySQL database is in the works).
Sorry about any confusion with deleting the project!
Cheers,
Tyron
|
|
|
|
|
Please is it possible to convert .net 2.0 code/program made with vs2005 to .net 3.0 in vs2008 to use some features of .net 3.0?
Thanks
phatkin
|
|
|
|
|
prubyholl wrote: Please is it possible to convert .net 2.0 code/program made with vs2005 to .net 3.0 in vs2008 to use some features of .net 3.0?
Open the VS2005 solution in VS2008 and the wizard will convert it for you.
If you want to make use of .NET 3.0 language features, you will have to modify the code yourself.
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
You can open the solution/project in VS2008 and it'll convert the solution/project files to the 2008 format, but it will NOT convert the code for you.
The code should run without issues in most cases. But, if you want to use the .NET 3.0, and above, features, you'll have to rewrite the code by hand to use them. There is no conversion tool that will look for patterns in your code and rewrite it for you.
|
|
|
|
|
Good Morning All
Firstly i would love to thank Dave for the Contribution he made into my Programming skills. number two, lets get to the problem.
i have Succeeded coding without any wizard involved.Thanks to Dave, now i have a Datagrid and am updating only one Field "Tshwane_Prediction", now in my Datagrid i have a button that will Search the for records based on an input, well that works fine and i will update one record from the records and click on Save, the Save button will Confidently send me a Update message and Walla!!!! its done, but my Problem here is that the Returned records will all assign one values, that i have assign to one Record. that means there is something wrong with my update Query.
my Update looks like this
<br />
Dim strUpdate As String = "UPDATE Property_mass SET Tshwane_Prediction = @Tshwane_Prediction" & _<br />
" WHERE (Tshwane_Prediction = @Original_Tshwane_Prediction OR @Original_Tshwane_Prediction IS NULL AND Tshwane_Prediction IS NULL) " & _<br />
" ;SELECT Primary_ID, Boundary_area, Attrib_Code, Lis_Key, Func_Key," & _<br />
" Actual_Extent, Improved_Value, Site_Value, Purchase_price," & _<br />
" Purchase_date, prop_id, confidence_score, fin_ls_prediction, " & _<br />
" new_lis_key, new_func_key, Tshwane_Prediction, matchflag," & _<br />
" source, flagtype FROM Property_mass WHERE (Primary_ID = @Original_Primary_ID)" & _<br />
" ; Update Property_Mass " & _<br />
" set Locked = Null " & _<br />
" WHERE (SUBSTRING(Lis_Key, 1, 4) = @Lis_key And Locked=1) "<br />
<br />
If you have any Article or Tutorial that Explain this Step please send me a link.
Thanks you
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
Hill i solved it, but part of it
i should have included the Primary_key Field that will be mapped in my vb.net code to the original source like this
<br />
Dim strUpdate As String = "UPDATE Property_mass SET Tshwane_Prediction = @Tshwane_Prediction" & _<br />
" WHERE (Primary_ID =@Original_Primary_ID) And (Tshwane_Prediction = @Original_Tshwane_Prediction OR @Original_Tshwane_Prediction IS NULL AND Tshwane_Prediction IS NULL) " & _<br />
" ;SELECT Primary_ID, Boundary_area, Attrib_Code, Lis_Key, Func_Key," & _<br />
" Actual_Extent, Improved_Value, Site_Value, Purchase_price," & _<br />
" Purchase_date, prop_id, confidence_score, fin_ls_prediction, " & _<br />
" new_lis_key, new_func_key, Tshwane_Prediction, matchflag," & _<br />
" source, flagtype FROM Property_mass WHERE (Primary_ID = @Original_Primary_ID)" & _<br />
" ; Update Property_Mass " & _<br />
" set Locked = Null " & _<br />
" WHERE (SUBSTRING(Lis_Key, 1, 4) = @Lis_key And Locked=1) "<br />
<br />
<br />
<br />
<br />
<br />
but Below as you can see there is a Query that updates the Lock if the transaction is Successfull. its Supposed to update the Field to Null when ever the update has taken place. The Problem is that am trying to update based on Search criteria used in the select, so my mistake was that i recreated the Parameter and expected it to carry the value of the sql parameter in the Select statement of the Selected command. So i need to know how to Carry that Value So that i can update the records based on it
Thanks
Please help
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
modified on Tuesday, January 15, 2008 5:13:20 AM
|
|
|
|
|
Move all this SQL code to a stored procedure in the database and this shouldn't be a problem.
I hate the idea of setting a Locked field in the first place, but that's up to you. It not really a supportable solution and can get you in trouble if your code unexpectedly quits for some reason, since the Locked fields will never clear.
|
|
|
|
|
Thanks Dave
Will do, after all a Stored Procedure will will Execute the All these statements,
Thanks
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
hi all
i am facing a problem called query is too complex.
what exactly i m doing is i have a richtextbox. i copy some text from doc file and paste it into richtextbox. then run a insert query that will insert the whole rtf to the database but this cause the error message query is too complex.
can some one tell me how to save the whole rich text of a richtextbox to a database, the field is memo.
thanks in advance.
help everyone
Falling down is not defeat...defeat is when u refuse to get up...
|
|
|
|
|
What does the query look like that's doing the INSERT??
What does the code look like that sets this up and executes the query??
What is the column type of the table that the RTF is going into??
|
|
|
|
|
Hi,
I am working on project and it's dealing with more than 100 textboxes and all of them has to be on single form. Does anyone know how can I add vertical scrollbar? I added control but it didn't seem to work, may be I didn't do something?! I would really appreciate it...
|
|
|
|
|
Hi,
this is the .NET approach, I don't know if it also works for MFC:
put a full-size Panel on the Form and set its AutoScroll true, then add
all the Controls to that Panel.
Luc Pattyn [Forum Guidelines] [My Articles]
This month's tips:
- before you ask a question here, search CodeProject, then Google;
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get;
- use PRE tags to preserve formatting when showing multi-line code snippets.
|
|
|
|
|
I can no longer access my main form in my project in designer mode. I now get the following error:
"Could not find type 'WindowsApplication1.CollapsiblePanel'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built."
CollapsiblePanel is a custom control that I have built. I have several of them on a form. I then get additional error statements saying:
"The variable 'ClpsPnlOutputOptions' is either undeclared or was never assigned." Here ClpsPnlOutputOptions is the name of one of the collpapsible panels on my form. I get errors for all these controls
Note I can run the project in designer mode but I cannot see the form in designer mode and accordingly cannot access any of my code that sits behind the code ( note I can see code in the Form1.Designer.Vb)
I am not sure why this is happening. I did some searching on-line and came up with a hotfix for VS 2005 Express:
https://connect.microsoft.com/VisualStudio/Downloads/DownloadDetails.aspx?DownloadID=3981&wa=wsignin1.0
But this has not done anything for me. I really don't know what I have done.
Can someone please provide advice on this error as I am stalled dead in my tracks.
Thanks
EM
|
|
|
|
|
ExcelMonkey wrote: Could not find type 'WindowsApplication1.CollapsiblePanel'
Is this class part of the same project, or is it a different project in the same solution, or is it a seperate project (not in this solution) that you're setting a reference to??
ExcelMonkey wrote: The variable 'ClpsPnlOutputOptions' is either undeclared or was never assigned
Or it's possible that this project has a coding error in it that makes the control fail. Since when you drop a control on a form at design time you're actually running the code in the control, this message is a definite possibility.
|
|
|
|
|
Its a class in the same project. I have 1 project with multiple forms, three class modules, 1 regular module.
I am trying to think back to what I may have done. It was working fine the last time I was using it. Now, I cannot even see my form or my code. At some point I added an event to the CollapsiblePanel Class and then an event handler in my main sub to restrict the number of CollapsiblePanles open at any one time. Then I renamed all my CollapsiblePanels. However, everything was working fine after I did this so I am not sure this is it.
I was also wondering if someone may have hit the keyboard while my code was open and entered a few keystrokes in the class module (i.e. my little boy - 20 months old). This is not farfetched but unlikely.
Is there any type of audit I can do to get more information? I could reveiw the Class module as I think its still visible. Its just the main form that is hidden (i.e this form has the collapsible panels on it).
As noted, the hotfix didn't do a thing.
I am literally stuck and cannot move on as all my code sits behind this form.
Thanks
EM
|
|
|
|
|
And everything compiles with no errors or warnings?
As a "work around" (backup your entire project folder FIRST!), I'd get into the designer generated code of the form and remove all traces of your control being instantiated. Yo ushould then be able to go back to the designer and see the form again. Drop a single instance of your control back onto the form, with the same name it had previously as see what happens. If the designer doesn't crash, you'll probably be in good shape to add the remaining instances, again, naming the same as they were before.
If it does crash, then you've got a problem in your control somewhere, either in it constructor (New), or in some code that does painting or some other event.
Sometimes Visual Studio looses it's mind and a control that used to work no longer does because the designer generated code gets all hosed up. I've found that removing the instances of the "offending" control and readding them usually fixes the problem.
|
|
|
|
|
So yes it run. But I do get Warnings/Errors. The first speaks to the assembly and reference. I then get Type errors saying that variables were not declared in the form code - when in fact they were.
"remove all traces of your control being instantiated"
What do you mean by this? I can get into the form generated code but I am not sure what I am looking for or what to do. Do you mean delete all the code in the form generated code?
"Drop a single instance of your control back onto the form, with the same name it had previously as see what happens. "
My panels have a lot of other controls in them. So I am basically removign everything - correct? I have had this problem before and simply rebuilt. What's to say that this will not keep happening?
"If it does crash, then you've got a problem in your control somewhere, either in it constructor (New), or in some code that does painting or some other event"
Where would the problem be in the constructor (NEW)? I believe my type errors refer to these (i.e. variable not declared).
Regards
EM
|
|
|
|
|