Help on making and using Database in VB

Thread Solved
Reply

Join Date: Dec 2006
Posts: 3
Reputation: fskhan is an unknown quantity at this point 
Solved Threads: 0
fskhan fskhan is offline Offline
Newbie Poster

Help on making and using Database in VB

 
0
  #1
Dec 22nd, 2006
Hi
I am developing an automation system using PC. I have built quite a big hardware but when it comes to Visual Basic, I am a novice. I have done a lot but need help in using database. I know how to link it in VB, i.e by using datacontrols(i prefer it over adocontrols) and linking them with labels etc BUT I dont know how to create a database and how to extract and use its data.
The database i need would contain date,time, id and operations field. Can any one tell me how can i create such a db in VB using visdata or in MS-access.... which ever is easiest

And how do I extract the date/time and compare it with current PC time.. then if found matched read other field values else progress forward.
Can anyone help me around on these "simple" issues. Codes or links to tutorials will do great!
Reply With Quote Quick reply to this message  
Join Date: Apr 2005
Posts: 15,990
Reputation: jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all 
Solved Threads: 511
Moderator
Featured Poster
jbennet's Avatar
jbennet jbennet is offline Offline
Moderator

Re: Help on making and using Database in VB

 
0
  #2
Dec 22nd, 2006
make the database in MS access thats the easiest
If i am helpful, please give me reputation points.
Reply With Quote Quick reply to this message  
Join Date: Nov 2006
Posts: 848
Reputation: QVeen72 is on a distinguished road 
Solved Threads: 120
QVeen72's Avatar
QVeen72 QVeen72 is offline Offline
Practically a Posting Shark

Re: Help on making and using Database in VB

 
0
  #3
Dec 25th, 2006
Hi,

Use MS-Access,
Go to MS-Access, Select NewDatabase Option,
Enter Path and Name , Say Create.
Click On New-->>Design View-->> OK
Enter Field Name, Type : Date/Time (Stores Both).

In VB, to get System Date :
Format(Date,"dd-mm-yyyy")
System Time :
Format(Now,"hh:mm:ss")

Compare Dates :
If Format(CDate(Text1.Text),"dd-mm-yyyy") =
Format(Date,"dd-mm-yyyy") Then
' Write ur coding Here
End If

Regards
Veena
Reply With Quote Quick reply to this message  
Join Date: Dec 2006
Posts: 3
Reputation: fskhan is an unknown quantity at this point 
Solved Threads: 0
fskhan fskhan is offline Offline
Newbie Poster

Re: Help on making and using Database in VB

 
0
  #4
Dec 25th, 2006
Originally Posted by QVeen72 View Post
Hi,

Use MS-Access,
Go to MS-Access, Select NewDatabase Option,
Enter Path and Name , Say Create.
Click On New-->>Design View-->> OK
Enter Field Name, Type : Date/Time (Stores Both).

In VB, to get System Date :
Format(Date,"dd-mm-yyyy")
System Time :
Format(Now,"hh:mm:ss")

Compare Dates :
If Format(CDate(Text1.Text),"dd-mm-yyyy") =
Format(Date,"dd-mm-yyyy") Then
' Write ur coding Here
End If

Regards
Veena
Thanks... that was great help. It was the same kind of code that I needed. But all to thanks Allah i had already accomplished the task. Got a hand on a very good tutroial on VB, perfect for novice and enough to build real applications. Incase anyone ever need help, i am listing the web address of that tutorial.

www.vbtutor.net

I'll include a bit of my intro as well as i am a newbie on this website. I am a student of Electronics Engg. and am building an automation system using Powerline Communications based on Personal Computer and Embedded Systems. Needed help for the same... and incase anyone ever find any problems in area listed above.. plz donot hesitate to ask..(send a private msg)

tc thanks
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC