|
[QODBC-Online] Using QuickBooks Online Data with VBA
Posted by Rajendra Dewani (QODBC Support) on 10 August 2015 03:20 PM
|
|
Using QuickBooks Online Data with VBACreating a Form in Microsoft Access:Note: Microsoft Access has many uses and will allow you to use your QuickBooks Online Data files similarly to Access databases. Open MS Access. You can find it via Windows Start->All Programs->Microsoft Office : A default database file, named Database1, appears in the box. You can edit this to a more relevant name, such as QuickBooks Link. accdb. Save the file as type "Microsoft Office Access Databases". Then, click "Create" to create a blank database:
After the new database is created, create a New Form via the "Form Design" link in the Create Tab:
After the new form is created, insert a button in the form:
Rename the button as per your requirement (In this example, the button name is "Select Customer"): Now go to the button property window and set the property for the "On Click" event. Select "Event Procedure" from the dropdown list, then click on the "..." button:
The new window is open, which contains the VBA code (In this example, it has a code button click event):
Now, insert the module in the form by right-clicking on the form:
Write code in the module (In this example, I am writing code for the selection of the customer name):
*Note: Use "QuickBooks Online Data" instead of "QuickBooks Data."
Link the newly created module with the button click event:
Now click on the "Select Customer" button, and you will get the names of all customers:
Repeating the above steps can add functionality to your VBA code as per your requirement. In this example, I have added functionality for inserting, Update & Delete of customer records: By clicking on the "Insert Customer" button, the New customer is added with the name "Testing VB":
By clicking on the "Update Customer" button, the newly added customer name is updated with the name "Updated Testing VB":
By clicking on the "Delete Customer" button, the newly added customer is deleted: Please refer to the code below code which is used in this example: Select Customer: Public Sub example select() Insert Customer: Public Sub exampleInsert() Update Customer: Public Sub exampleUpdate() Delete Customer: Public Sub exampleDelete()
Tags: QuickBooks Online, QBO, Access, MS Access, QODBC Online VBA, VBA script, sample VBA online
| |
|
|













