Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel Example

Status
Not open for further replies.

BruceVBA

Programmer
Apr 18, 2002
3
GB
If anyone can help me with the database question I asked about earlier, I have prepared an example in Excel 97 if anyone could take a look at it for me. I was originally asking how I would be able to write code in VBA enabling me to:

1. Acknowledge a 'Project Name' selection made by a user, from a combobox list.
2. Attempt to locate the selection from a database column.
3. Locate another 'date' selection corresponding to the range found for that particular 'project name'.
4. If an entry has not been made for that particular 'date' then the data must be entered in the correct row corresponding to that date and project.

As I said if anyone is prepared to suggest some code that I might need to be able to carry out these tasks then please let me know and I can forward you a copy of the spreadsheet so that you can see what I am getting at!!

Many thanks in advance.

Regards,

Bruce
 
BruceVBA,

1. Your ComboBox LIST ought to be a summary right out of the Project Name column of your table. Then there will be not "attempt" to find a row(s) -- you WILL return a resultset.

2. Based on the resultset, you can test your date. If the date is not found, then insert a row or update some row in your resultset.

Seems pretty simple. :). Skip,
metzgsk@voughtaircraft.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top