>How do I add a record on MSACCESS table getting the values from a texbox or combobox using the INSERT INTO-SQL command?
Hi Victor,
1. First of all you have to define an ODBC data source for the Access MDB you want to update using 32-bit ODBC admin in Control Panel.
2. Issue lnhandle = SQLCONNECT() from command window.
3. Locate the ODBC Data Source you have created. This will return connection handle in lnhandle varibale.
4. Use lnhandle this varible in SQLEXECUTE() func as follows.
=SQLEXECUTE(lnhandle,"insert into mytable value (......)")
You can do the same thing in the form using the value of ComboBox and TextBox.
lcval = Thisform.txttry.Value
=SQLEXECUTE(lnhandle,"insert into mytable value (?lcval,.....)")
Bye
Jayesh
- Jayesh