ActiveState Community

Tcl App Wraping files

Posted by satya on 2009-02-10 17:48

Hi,

I am new to TclApp, i am using tclApp 5.0 for making a tcl executable. I am able to Wrap files and make an executable and run the same. The problem i am facing is if i remove files locally from my system and run the executable it is still looks for the file and says file does not exists.

couldn't read file "C:/check /Profiles.tcl": no
such file or directory
while executing
"source "$mypath/Profiles.tcl""
(file "C:/Documents and Settings/Desktop/test.exe/lib/a
pplication/test/TestManager.exp" line 122)
invoked from within
"source $startup"
(file "C:/Documents and Settings/Desktop/ test.exe/main.
tcl" line 34)

How could i solve this problem, i need to deliver as an executable where in user system he wont have any of the files. how do i make tclapp to see the files.

Thanks in Advance,

andreas.kupries | Tue, 2009-02-17 13:35

Hello satya.

I have a question for you, the answering of which I believe should help us and you to diagnose where your problem is.

First, from the stack the file it your application tries to source is "C:/check /Profiles.tcl", outside of the wrapped application, which is wrong.

We also see that the command with the problem is "source "$mypath/Profiles.tcl".

From both items together we can deduce that the variable "mypath" is set to "C:/check ". It is quite apparently pointing to a directory outside of test.exe instead of where Profiles.tcl is stored in test.exe.

To see why that happens, can you tell me a bit more how this variable is handled by your code ?

(I am assuming that Profiles.tcl is listed in your TclApp Project (.tpj file) and wrapped.).