Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,153,036 members, 7,818,059 topics. Date: Sunday, 05 May 2024 at 06:17 AM

Vb.net Help - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / Vb.net Help (1225 Views)

ASP.NET HELP!¡! Any Programmer Can Give Suggestion. / I Need A Help To Write A Simple Login Form Using Vb.net / Post Ur Vb 6.0 Questions Here (2) (3) (4)

(1) (Reply) (Go Down)

Vb.net Help by Nobody: 10:30am On Feb 28, 2012
Dim con As New OleDb.OleDbConnection
Dim dbprovider As String
Dim dbsource As String
Dim ds As New DataSet
Dim da As OleDb.OleDbDataAdapter
Dim sql As String


dbprovider = "provider=microsoft.Jet.OLEDB.4.0;"
dbsource = "Data source=C:\Users\VICTOROUS ARMY\Desktop\NWIND.mdb"
con.ConnectionString = dbprovider & dbsource
con.Open()
Sql = "SELECT * FROM Employees"
da = New OleDb.OleDbDataAdapter(Sql, con)
da.Fill(ds, "NWIND"wink


Dim cb As New OleDb.OleDbCommandBuilder(da)
Dim dsNewRow As DataRow
dsNewRow = ds.Tables("NWIND"wink.NewRow()
dsNewRow.Item("LastName"wink = TextBox1.Text
dsNewRow.Item("FirstName"wink = TextBox2.Text
ds.Tables("NWIND"wink.Rows.Add(dsNewRow)
da.Update(ds, "NWIND"wink
MsgBox("New Record added to the Database"wink



PLS ANY ONE WHO CAN HELP ME WITH CODE ON HOW TO SEARCH,DELETE,UPDATE,VALIDATE USER LOGIN,NAVIGATE RECORD IN DATABASE BUT THE ABOVE CODE IS THE CODE I USE IN SAVING RECORD
ANYONE WHO CAN HELP ME WITH THE CODE TO SEARCH,DELETE,UPDATE,VALIDATE USER LOGIN,NAVIGATE RECORD IN DATABASE WITH THE HELP OF WINDOW FORM IN MICROSOFT VISUAL BASIC
2008 EXPRESS EDITION WITH ACCESS DATABASE AND MICROSOFT SQL SERVER DATABASE
Re: Vb.net Help by dellnet: 3:50pm On Feb 28, 2012
Depends on what library you are using. Me, I prefer to use ADO so I can use SQL statements. For example to search for a username, I will get the username say from a textbox and put it in sql statement. E.g

Dim sqlquery as string = "SELECT * FROM table WHERE username=" & txtuser.text

Now I will use the above and search my db. If you are interested in using ADO you should learn the following:
1. How to connect to a database using ADO
2. How to select, update, delete a database using ADO

These are pretty easy stuffs.
Re: Vb.net Help by Kobojunkie: 5:15am On Feb 29, 2012
@Poster

        dbprovider = "provider=microsoft.Jet.OLEDB.4.0;"
        dbsource = "Data source=C:\Users\VICTOROUS ARMY\Desktop\NWIND.mdb"
        con.ConnectionString = dbprovider & dbsource

Please take a look at this link to learn what a connectionString is and how to format it   . .  http://www.connectionstrings.com/Articles/Show/what-is-a-connection-string

http://www.connectionstrings.com/sql-server-2008#p2

Also, when you run code, and get an error. It is usually best if you provide us with details of the error so we can best understand what problem you are really having.
Re: Vb.net Help by AZeD1(m): 2:20pm On Feb 29, 2012
I'm more of a stored procedure person.
KoboJunkie are you a programmer?
Re: Vb.net Help by 9ja4eva: 6:48pm On Mar 03, 2012
Kobojunkie:

@Poster

Please take a look at this link to learn what a connectionString is and how to format it   . .  http://www.connectionstrings.com/Articles/Show/what-is-a-connection-string

http://www.connectionstrings.com/sql-server-2008#p2

Also, when you run code, and get an error. It is usually best if you provide us with details of the error so we can best understand what problem you are really having.


Kobo do u program in VB? I got a question for you
Re: Vb.net Help by Kobojunkie: 12:07am On Mar 04, 2012
I think I have posted a response to your question. Please check it.
Re: Vb.net Help by 9ja4eva: 6:00am On Mar 04, 2012
Yeap Boss i have checked it. I have another concern if you don't mind.

(1) (Reply)

Why Do Nigerians Adore Hardware But Despise Software and its Makers? / Help On Html Code That Displays Form Details After Submitting Form / Website Designer, Web Developer In Asaba Delta State

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 14
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.