Hi, hope someone can help me with this. No one has been able to so far! Surely there must be someone out there who knows this?
I've set up a basic windows form in Visual Studio 2005. All it has is Name, and Surname, with a textbox for each.
I've also set up a table in a database in SQL2005, with two columns, Name and Surname.
My layout is all complete in visual studio, I've linked the database to the form from the data wizard, but how do I now set this up so that
when I click a button on the form, it sends the data entered in the textboxes to my table in SQL?
I know how to insert and view data using T-SQL in SQL management studio, but how do I do it through my application.
Thanks in advance.
Linking a Form to a SQL Database
Started by newguy15, Nov 30 2007 05:26 AM
2 replies to this topic
#1
Posted 30 November 2007 - 05:26 AM
|
|
|
#2
Guest_Jordan_*
Posted 30 November 2007 - 05:40 AM
Guest_Jordan_*
What are you using in Visual Studio 2005? C#, VB, C++?
Here is the MSDN reference that should help you out: Connecting to Data in Visual Studio
Here is the MSDN reference that should help you out: Connecting to Data in Visual Studio
#3
Posted 04 December 2007 - 12:13 AM
Thanks Jordan.
I would use VB.I'm very new to programming so would try VB first.
I've worked out how to display my textbox input in a msgbox, but would like to be able to send it to my table i've created in SQL.I've linked a SQL database to my app.
How do I do this in VB so that this happens when I click the button. Is it a stored procedure or trigger or something>
Thanks
I would use VB.I'm very new to programming so would try VB first.
I've worked out how to display my textbox input in a msgbox, but would like to be able to send it to my table i've created in SQL.I've linked a SQL database to my app.
How do I do this in VB so that this happens when I click the button. Is it a stored procedure or trigger or something>
Thanks


Sign In
Create Account

Back to top









