Hello forum,
I am new to the website but hope you can help me out. I am new to vb programing but have some limited programing in the past so I am picking it up pretty quick. Below is a example of what I am trying to use vlookup on:
Vehicles Type Name phone laptop printer
E201 1078 Mike 67567653 423423 k34234
E202 1078 John 234231 55234423 231244
E203 1152 Jados 55234423 423423 55234423
E204 1152 Cramer 234231 55 234423 231244
E206 1114 Napier 55234423 423423 55234423
E310 M88A1 Joe 234231 55234423 231244
E870 1078 Chon 55234423 423423 55234423
E871 1078 Dubbs 234231 55234423 231244
E873 1114 Rob 55234423 423423 55234423
E877 1078 Spann 234231 55234423 231244
This is a list of company vehicles and genric serial numbers for the particular people. I am using a 4 comboboxes on userform plus a ok button. Combobox 1 is the drop down for column A. Combobox 2-4 are for column C. My goal is to create a program that when I select a vehicle from combobox 1 and people from combobox 2-4, that it will write to cells in the formatt that I want and it will vlookup the serial number for those people. I have it working but I have a issue. My vlookup reference changes cells when I start the second vehicle since I offset formatt with a counter. This is how I would like it to look
1 E873 dubbs 234231 55234423 231244
Napier 55234423 423423 55234423
Cramer 55234423 423423 55234423
Chief 234231 55234423 231244
2 E873 dubbs 234231 55234423 231244
Napier 55234423 423423 55234423
Cramer 55234423 423423 55234423
Chief 234231 55234423 231244
3 E873 dubbs 234231 55234423 231244
Napier 55234423 423423 55234423
I end up getting N/A's because I dont know how to use cell with the name as the reference if its location is shifting every vehicle with offset. I have been trying to use a offset value with a counter to try and get what I want. Intitally it works but fails as the counter goes up. Any advise?
Bookmarks