MacroMan007
New Member
- Joined
- Aug 5, 2005
- Messages
- 35
Hello, I have a quick question I hope and is probably very easy, but I am fairly new to VB... I can tweak code, but I'm not so good at starting from scratch.
So, here's what I would like the simple user-form to do. I have an existing table (on a read-only sheet) that has 5 columns (in this order):
Contract Number (A), Company Name (B), Status (C), Date (D) and an Expiration Date (E).
Now, all I would like it [the user-form] be able to do, is with either 2 combo boxes (one to select the Contract Number and the other to choose the new Status) or just one combo box to change the active row's Status. If a contract number box is used, then it will need to find the correct row and then change the status; otherwise then the user would have to select the row first and then activate the user-form and select the status.
I have a named range for the Status List I want to use for the combo box and if 2 combo boxes were used, then Column A would hold the listing of contract numbers.
So, for example, what user-form code would I need if I wanted to change the status (and it would only ever be the status) in say row 2, from Active to Deleted.
I'm stumped and I have Googled and looked at a lot of code, but nothing seems to address what I'm looking for. It's also possible I'm making it way too complicated. I can certainly make some code to just have a macro change the correct cell for the active row to Deleted, but I was looking for it to be more interactive... so the used can select different options from a drop-down listing.
Thanks in advance for any help you can give me.
Jay
So, here's what I would like the simple user-form to do. I have an existing table (on a read-only sheet) that has 5 columns (in this order):
Contract Number (A), Company Name (B), Status (C), Date (D) and an Expiration Date (E).
Now, all I would like it [the user-form] be able to do, is with either 2 combo boxes (one to select the Contract Number and the other to choose the new Status) or just one combo box to change the active row's Status. If a contract number box is used, then it will need to find the correct row and then change the status; otherwise then the user would have to select the row first and then activate the user-form and select the status.
I have a named range for the Status List I want to use for the combo box and if 2 combo boxes were used, then Column A would hold the listing of contract numbers.
So, for example, what user-form code would I need if I wanted to change the status (and it would only ever be the status) in say row 2, from Active to Deleted.
I'm stumped and I have Googled and looked at a lot of code, but nothing seems to address what I'm looking for. It's also possible I'm making it way too complicated. I can certainly make some code to just have a macro change the correct cell for the active row to Deleted, but I was looking for it to be more interactive... so the used can select different options from a drop-down listing.
Thanks in advance for any help you can give me.
Jay