Click here to Skip to main content
15,896,153 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: truncate table in sql 2005 by vb,net code Pin
atk88774-Jun-09 1:32
atk88774-Jun-09 1:32 
QuestionExport Excel Formula Pin
ross16642-Jun-09 5:51
ross16642-Jun-09 5:51 
AnswerRe: Export Excel Formula Pin
Kschuler2-Jun-09 5:59
Kschuler2-Jun-09 5:59 
GeneralRe: Export Excel Formula Pin
ross16642-Jun-09 19:18
ross16642-Jun-09 19:18 
QuestionVB.net: How to update database from datagridview Pin
Roger Rainey2-Jun-09 4:35
Roger Rainey2-Jun-09 4:35 
AnswerRe: VB.net: How to update database from datagridview Pin
Kschuler2-Jun-09 5:45
Kschuler2-Jun-09 5:45 
QuestionRe: VB.net: How to update database from datagridview Pin
JohannNutter22-Jul-09 9:08
JohannNutter22-Jul-09 9:08 
GeneralRe: VB.net: How to update database from datagridview Pin
Kschuler22-Jul-09 9:35
Kschuler22-Jul-09 9:35 
I agree with you, that the question is valid. I just felt like it was too broad a topic and requires more information to decently answer in the forums as is.

I haven't really ever used VB6, so I'm not aware of the differences between it and VS2003 or above. As for how to add the add/update/insert statement easily, it also depends on the data provider you are using. If you use OleDb or SqlClient you should be able to use a CommandBuilder. You just need to write the Select SQL Statement, set it to the DataAdapter, and then put this statement (if using SqlClient provider):
Dim cb As New SqlClient.SqlCommandBuilder(myDataAdapter)
before you call the update method of the DataAdapter object. It's also a good idea to clean up after the update with this statement:
cb.Dispose()

I'm not sure if it works exactly the same way if you are working primarly in design mode, as I mostly code all my database stuff instead of using the visual studio designer to drag and drop DataAdapters, Connections, etc.

Since there are so many possible scenarios, it's hard to give more advice than this. Which is why it's so much better to post your code when asking for help. Please post what you have for your update and we can give you some help and advice on what is not working.
GeneralRe: VB.net: How to update database from datagridview Pin
JohannNutter22-Jul-09 10:26
JohannNutter22-Jul-09 10:26 
QuestionVBA and XL - Is this a Viable Function Request? [modified] Pin
Dalek Dave2-Jun-09 4:18
professionalDalek Dave2-Jun-09 4:18 
AnswerRe: VBA and XL - Is this a Viable Function Request? Pin
David Mujica2-Jun-09 4:55
David Mujica2-Jun-09 4:55 
GeneralRe: VBA and XL - Is this a Viable Function Request? Pin
Dalek Dave2-Jun-09 5:02
professionalDalek Dave2-Jun-09 5:02 
GeneralUnderstood Pin
David Mujica2-Jun-09 5:15
David Mujica2-Jun-09 5:15 
GeneralRe: Understood Pin
Dalek Dave2-Jun-09 5:23
professionalDalek Dave2-Jun-09 5:23 
Questionrandom access files .net 2005 Pin
vurdmal2-Jun-09 3:22
vurdmal2-Jun-09 3:22 
AnswerRe: random access files .net 2005 Pin
DidiKunz2-Jun-09 3:34
DidiKunz2-Jun-09 3:34 
GeneralRe: random access files .net 2005 Pin
vurdmal2-Jun-09 4:09
vurdmal2-Jun-09 4:09 
GeneralRe: random access files .net 2005 Pin
Jay Royall2-Jun-09 4:40
Jay Royall2-Jun-09 4:40 
GeneralRe: random access files .net 2005 Pin
vurdmal2-Jun-09 5:10
vurdmal2-Jun-09 5:10 
GeneralRe: random access files .net 2005 Pin
Jay Royall2-Jun-09 5:24
Jay Royall2-Jun-09 5:24 
GeneralRe: random access files .net 2005 Pin
vurdmal2-Jun-09 6:26
vurdmal2-Jun-09 6:26 
GeneralRe: random access files .net 2005 Pin
Jay Royall2-Jun-09 6:32
Jay Royall2-Jun-09 6:32 
Questionhow to embed hardware info programmatically to an executable at install time Pin
JayKhatri2-Jun-09 2:06
JayKhatri2-Jun-09 2:06 
AnswerRe: how to embed hardware info programmatically to an executable at install time Pin
DidiKunz2-Jun-09 3:24
DidiKunz2-Jun-09 3:24 
GeneralRe: how to embed hardware info programmatically to an executable at install time Pin
JayKhatri4-Aug-09 4:36
JayKhatri4-Aug-09 4:36 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.