Solved

asp.net/vb.net using databases programmatically

Posted on 2014-03-24
6
26 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

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
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.
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.

895 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