check if this code template works
Code:
'function library file
function f1(obj)
set wb=obj.workbooks.open("c:\.....\.xls")
set sh=wb.worksheets(1)
'do some operation
set f1=obj
set wb=nothing
set sh=nothing
end function
function f2(obj)
set wb=obj.workbooks.open("c:\.....\.xls")
set sh=wb.worksheets(1)
'do some operation
set f2=obj
set wb=nothing
set sh=nothing
end function
'action script
set e=createobject("excel.application")
set e= f1(e)
set e=f2(e)
set e=nothing