Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
opening file with worksheetfunction
Hello everybody.
I'm trying to create a worksheetfunction in Excel 97 that should ope another excel-file. This is how it looks now (in a module): Public Function AZ (iUserInput as Integer) as Integer workbooks.open "c:\etc\etc.xls" AZ = iUserInput * 2 End Function Now when I type in a worksheet in the same workbook =AZ(3) I get #VALUE! The code simply doesn't open the file. On the other hand it does wor when I start the function from the module. And I tested it as a sub: i worked. I have put the code in a worksheet event: it worked again. Why is it not possible to use a self-defined worksheetfunction to ope a file -- Message posted from http://www.ExcelForum.com |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
opening a file in Excel starts application but dose not open file | Excel Discussion (Misc queries) | |||
Opening file in Excel 2003 opens multipule instances of same file | Excel Discussion (Misc queries) | |||
File:1 and File:2 -- Double Files when Opening One File | Excel Discussion (Misc queries) | |||
opening an excel file opens a duplicate file of the same file | Excel Discussion (Misc queries) | |||
WorkSheetFunction.CountIf & WorkSheetFunction.SumIf with 2 conditions? | Excel Programming |