Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Excel VBA and Access communication
Name: MartyDean Date: June 6, 2005 at 13:24:22 Pacific OS: Windows XP Pro CPU/Ram: 3.8 / 1g
Comment:
I am new to VBA, I am trying to use text boxes to input data into and retrieve data from an Access Database. I am not having any success. Here is the coding I have so far. Try not to laugh :\
Private Sub cmdEnter_Click() Dim txtFig As Integer Dim txtItem As Integer Dim txtPart As String Dim txtGrove As String Dim txtUnitPrice As Integer Workbooks("Sheet2").Activate Cells(2, "E").Value = txtFig Cells(4, "E").Value = txtItem Cells(6, "E").Value = txtPart Cells(8, "E").Value = txtGrove Cells(10, "E").Value = txtUnitPrice
End Sub
From here I have become lost, probally because I am trying to teach myself. Any help or hints would be greatly appreciated.
Name: MartyDean Date: June 6, 2005 at 13:36:09 Pacific
Reply:
I also have figured out how to import external data ( the access database I created ) though I do not know how to add new entries into the database itself, or display the data I import by using search parameters I am trying to define in the text boxes. Being txtItem, txtPart, txtFig and so forth.
Reguards, Marty
0
Response Number 2
Name: Grok Lobster Date: June 8, 2005 at 15:41:35 Pacific
Reply:
You have to open an instance of Access from Excel VBA and then open the database to make your changes. You should get a book on VBA if you don't have one already. John Walkenbach and John Green both have excellent ones widely available.
Summary: I have failed to find a comprehensible method of writing data to a serial and parallel port on a PC using Excel VBA. I wish to send control code (ESC/P2 codes) to an Epson dot matrix printer and send ...
Summary: Hi there! I'm just beginning the long road in learning VBA and already have an immediate need for some code that is quite beyond me. I have an excel worksheet that contains thousands of rows of data i...
Summary: Hey guys,Im new to VBA. I have created a form in excel and I want to be able to query information from an existing database in access(excel 97 and access 97). I want to be able to ask the user of this...