Having problems Storing and Retrieving an Excel file in a Custom Property

Ian McKnight iangmcknight at gmail.com
Mon Apr 25 10:59:07 EDT 2011


Hi All

I have an excel file that I want to include in a standalone.
I created an excel template and copied it from its default location to the
same folder as my stack.
I imported it into a custom property.
The problem is that when I export the custom property contents back to disk
I can't access the file.
An excel template is created on disk but I get the following error when
trying to access it with Excel.

'masterTemplate.xlt cannot be accessed. The file may be read only, or you
may be trying to access a read-only location. Or, the server document is
stored on may not be responding.'

BTW I have also attempted the same thing with a standard excel file (.xls)
with the same affect.

Is there some information that is lost during this process that corrupts the
exported file?

I have had no problems in the past doing this with text files and pictures
so any advice would be greatly appreciated.



Here is my import and export code

import:

answer file "choose"
     if it is empty or the result is "Cancel" then exit to top

     put "file:"&it into fname
     set the cpExcelMaster of this stack to URL fname
-- 
Regards


Ian McKnight

iangmcknight at gmail.com
=======================



More information about the use-livecode mailing list