database
Discussion in "General help Guidance and Discussion" started by har Dec 31, 2007.
Mon Dec 31 2007, 11:17 am
how to create database and use it in Visual Basic annd further interface it with microcontroller
Mon Dec 31 2007, 03:48 pm
very simple :-)
1. make a database file using MSAccess ..
let u create a database named "students.mdb" which has a table in it named "info".
let this table contains 2 fields named..."name" and "age".
2.
then u declare a database in vb as
3.
then u initialize database in vb as
4.
thats it.....now u can create new records,edit,delete records from it.
for example to create a new record, u write as
hope it helps :-)
1. make a database file using MSAccess ..
let u create a database named "students.mdb" which has a table in it named "info".
let this table contains 2 fields named..."name" and "age".
2.
then u declare a database in vb as
Dim db As Database Dim rs As Recordset
3.
then u initialize database in vb as
Set db = OpenDatabase(App.Path & "\students.mdb") Set rs = db.OpenRecordset("info", dbOpenDynaset)
4.
thats it.....now u can create new records,edit,delete records from it.
for example to create a new record, u write as
rs.addNew rs.Fields("name")="abbas" rs.Fields("age")="20" rs.upDate
hope it helps :-)
har like this.
Wed Jan 02 2008, 10:56 am
how to collect data from microcontroller in your vb program. can u please explain me with one technical example.
Wed Jan 02 2008, 05:19 pm
let u have connected some sensor to uc.u want uc to read that sensor and send its data to pc (let say serially).
for this u first program ur microcontroller.
then u make a program in vb which reads data from serial port.
so whenever ur controller will send data, vb program will collect it .
and u can do whatever u want with that data
hope it will be clear now
for this u first program ur microcontroller.
then u make a program in vb which reads data from serial port.
so whenever ur controller will send data, vb program will collect it .
and u can do whatever u want with that data
hope it will be clear now
Thu Jan 03 2008, 02:17 am
just a hint.. check for MSCOMM in your VB
go to Project->Components->Microsoft Comm Control
just drag and drop in your project..
go to Project->Components->Microsoft Comm Control
just drag and drop in your project..
Wed Jan 30 2008, 02:02 pm
why i can't define variable db as database? i use vb6 and ms access 2003
Powered by e107 Forum System