Home |
Search |
Today's Posts |
#13
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks to this thread I solved as well my problem with vlookup,
already started to bang my head against the wall. so definitely "Application.vlookup" is the solution. Problem: checking a list of unique values, to determine if a "ne value" to be added is really "new". If the value exists in the list I check, then the information to th right of the value is a "String" Solution: Code ------------------- MyResult = Application.VLookup(MyValue, Range(MyRange), 2, False) Select Case VarType(MyResult) Case vbError Select Case MyResult Case CVErr(2042) '"Data not found" 'This is the desired condition in my solution Case Else 'Another error occured that I dont know about MsgBox CStr(MyResult), , "vlookup" Exit Sub End Select Case vbString ' The Value was found, meaning my value is not unique. Exit Sub Case Else 'another vartype was returned that I did not expect MsgBox VarType(Result), , "vlookup" Exit Sub End Select ------------------- -- Message posted from http://www.ExcelForum.com |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Is there a way to unload the loaded XLL file in Excel? Hi all, I amdebugging XLL link library using Visual C++. Everytime I rebuild the XLL, Ihave to close the whole Excel program and relaunch the Excel program again,and then load in the newly gene | Excel Discussion (Misc queries) | |||
My Program | Charts and Charting in Excel | |||
merging excel program with tdc finance program | Excel Programming | |||
How to program a key, say F4? | Excel Programming | |||
run program | Excel Programming |