Hi everyone,
I have a very basic question about how to get data from a database to my code.
The idea is this:
There is a listbox on my form where a user picks something.
I have an acces mdb where the items from the listbox are listed alphabetically, and in another column there is a formula.
A user can select one item from the listbox, and I want vbcode to look for the corresponding formula, and load it into a variable without showing it in the form.
So basicly I am looking for a vb version of the excel code lookup. (because it needs to look for a unique value, and than retun a value next to it)
I use visual studio, and I have already managed to load the mdb file into my project, and I even managed to load the right column into the listbox.
All that is missing is the code to look for the formula and load it into a variable.
I really hope someone can help me with this, I have looked around, but most information is about non local databases or OLE is used (which I don't need because my database is already in my project, atleast thats what I think).
Thanks for your help in advance.
Greetings,
I have a very basic question about how to get data from a database to my code.
The idea is this:
There is a listbox on my form where a user picks something.
I have an acces mdb where the items from the listbox are listed alphabetically, and in another column there is a formula.
A user can select one item from the listbox, and I want vbcode to look for the corresponding formula, and load it into a variable without showing it in the form.
So basicly I am looking for a vb version of the excel code lookup. (because it needs to look for a unique value, and than retun a value next to it)
I use visual studio, and I have already managed to load the mdb file into my project, and I even managed to load the right column into the listbox.
All that is missing is the code to look for the formula and load it into a variable.
I really hope someone can help me with this, I have looked around, but most information is about non local databases or OLE is used (which I don't need because my database is already in my project, atleast thats what I think).
Thanks for your help in advance.
Greetings,