Solved

asp.net/vb.net using databases programmatically

Posted on 2014-03-24
6
21 Views
Last Modified: 2016-06-20
Hi - I'm new to asp.net, using VB.net.   I've gone through the basics of all these nice web controls, specifically to automate the pulling and displaying of data from databases using gridviews, etc.

However, I'm struggling to find a good tutorial of how to access, pull and manage data from a sql database using vb code, etc. not using these fancy web controls, but using code.


Can you recommend a link or two to tutorials that i can work from to understand how to have this greater level of control.

Thanks,
0
Comment
Question by:ErinTheCoderGirl
  • 2
  • 2
6 Comments
 
LVL 5

Expert Comment

by:jayakrishnabh
ID: 39950159
0
 

Author Comment

by:ErinTheCoderGirl
ID: 39950226
Hi - thanks but these both populate a gridview... is there a way to retrieve data from the database, and directly populate textboxes, etc.?
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 500 total points
ID: 39950825
Here is a simple example

Dim Conn As New SqlConnection(Connection_String)
Dim Comm1 As New SqlCommand(Command, Conn)
Conn.Open()
Dim DR1 As SqlDataReader = Comm1.ExecuteReader()
If DR1.Read() Then
	textBox.Text = DR1.GetValue(0).ToString()
End If
Conn.Close()

Open in new window

0
 

Author Comment

by:ErinTheCoderGirl
ID: 39951829
Hi, thanks for the example, but I am looking for tutorialson this.

Do you know of any tutorials that guide through programmatic database controls?
0
 
LVL 83

Assisted Solution

by:CodeCruiser
CodeCruiser earned 500 total points
ID: 39954444
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now