hi,
I am trying to use the function GET XLS LOOKUPS('file','tab','x row or col','cell') function to import data from EXCEL,
I have read the VEnsim Manual about this function, and it gives a example
regular lookup((0,0),(1,1))
excel lookup(GET XLS LOOKUPS('test.xls','Sheet2','1','B2')) ~~|
subbed excel lookup[shape](GET XLS LOOKUPS('test.xls', 'Sheet2','1' , 'B2')) ~~|
I am doing the same way, but it is not working.
Any one is happy to show me an working axample? or tell me how to do it?
Many thanks in advance.
Roger
How to use the GET XLS LOOKUPS function
-
- Junior Member
- Posts: 5
- Joined: Thu Mar 13, 2008 11:13 am
-
- Super Administrator
- Posts: 4827
- Joined: Wed Mar 05, 2003 3:10 am
Can you post the model you are testing with (and the Excel spreadsheet)?Originally posted by rogercai69
hi,
I am trying to use the function GET XLS LOOKUPS('file','tab','x row or col','cell') function to import data from EXCEL,
I have read the VEnsim Manual about this function, and it gives a example
regular lookup((0,0),(1,1))
excel lookup(GET XLS LOOKUPS('test.xls','Sheet2','1','B2')) ~~|
subbed excel lookup[shape](GET XLS LOOKUPS('test.xls', 'Sheet2','1' , 'B2')) ~~|
I am doing the same way, but it is not working.
Any one is happy to show me an working axample? or tell me how to do it?
Many thanks in advance.
Roger
Tony.
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm
I am guessing the confusion comes from the text syntax that is used in the Reference Manual. When you see
excel lookup(GET XLS LOOKUPS('test.xls','Sheet2','1','B2')) ~~|
That means you create a variable named "excel lookup" then open the equation editor, then select type Lookup, then enter the equation
GET XLS LOOKUPS('test.xls','Sheet2','1','B2')
The new lookup function "excel lookup" can then be used in equations as
output = excel lookup(input)
and so on.
I hope that helps.
excel lookup(GET XLS LOOKUPS('test.xls','Sheet2','1','B2')) ~~|
That means you create a variable named "excel lookup" then open the equation editor, then select type Lookup, then enter the equation
GET XLS LOOKUPS('test.xls','Sheet2','1','B2')
The new lookup function "excel lookup" can then be used in equations as
output = excel lookup(input)
and so on.
I hope that helps.
-
- Junior Member
- Posts: 5
- Joined: Thu Mar 13, 2008 11:13 am
Many thanks. It is working now as I follows your advice. In order to make it more clear, I quote your advice here.
"that means you create a variable named "excel lookup" then open the equation editor, then select type Lookup, then enter the equation
GET XLS LOOKUPS('test.xls','Sheet2','1','B2')
The new lookup function "excel lookup" can then be used in equations as
output = excel lookup(input) "
"that means you create a variable named "excel lookup" then open the equation editor, then select type Lookup, then enter the equation
GET XLS LOOKUPS('test.xls','Sheet2','1','B2')
The new lookup function "excel lookup" can then be used in equations as
output = excel lookup(input) "