Hello,
I've written some of this stuff in earlier posts, but it's required here too.

I have been trying to create an exe file of a Perl script and am using PerlApp which comes with ActiveState's PDK 5.0.
I'm using PerlApp to pack a .pl file along with text files and .pm's
perlapp myscript.pl --add mypm.pm --bind mytextfile.txt[text,extract,f +ile=c:\test,mode=0777]
Once we run the .exe file,the text files packed with the .exe get extracted in the c:\windows\temp folder in this way:
c:\windows\temp\pdk-username-856877
the process id gets appended to the folder name.
Suppose I use stmts like this to open mytextfile.txt in myscript.pl
open TF,'>mytextfile.txt' or die $!;
My .pl script can't find the text file. I keep getting this error:
Tk::Error: No such file or directory at test.pl line 183.[\&main::chfi +le]
According to the PerlApp docs, if we use the 'extract' option with --bind:
The bound file is extracted into the TEMP directory upon application s +tart. It will be deleted when the application terminates. The extract +ion directory will be added to the PATH environment variable (as well + as to the LD_LIBRARY_PATH variable on Unix). It will also be added t +o the front of @INC.
But the temp. folder in which the text files are extracted is not getting added to the PATH environment variable.
I tried adding it to PATH , while not quitting the application,but that also didn't work.What is the problem here? Please help!Thanks in advance.
:)

2006-01-19 Retitled by Arunbear, as per Monastery guidelines
Original title: 'PerlApp'


In reply to Writing to a packaged file with PerlApp by perl_seeker

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.