Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by jpasquini

  1. jpasquini

    storableedit file editor - anyone?

    I pronounce it "storaBLEED-it", because every time I use it, I feel slightly woozy as if I've lost blood. 'nuff said
  2. jpasquini

    storableedit file editor - anyone?

    Paul, I think there are a few people up the line that are very smart and bored. I really can't see what storableedit adds except complexity (converts text to a compliled storage format, then uncompiles it to display). You can no longer edit the data on the fly. It does allow you to pull...
  3. jpasquini

    storableedit file editor - anyone?

    Hi All, I have an application that displays Perl TK data files, and now the requirement has come down that we must use the 'storableedit' procedure to store the data. (storableedit 1.5). From what I understand this is kind of like a 'mini relational database', which saves files in a Perl...
  4. jpasquini

    image on a user button (groan....)

    Forum, Here's the answer to the above question: ## Add graphic (sample) my $pic_mailbox = $mw-> Photo ( -file => "${graphics}/flagup"); my $btn_release_cancel= $w_Commands -> Button( #-text => 'Exit', -command => \&_release_exit, -font => "{Arial} 11 {bold}", -image =>...
  5. jpasquini

    image on a user button (groan....)

    Hi all, Has anyone seen a quick and dirty example of adding a graphical image to a button in Perl TK? All I have is this monstrosity from the 'widget' module, which is like learning to drive the space shuttle to get to the mailbox......... # icon.pl use vars qw/$TOP/; sub icon { #...
  6. jpasquini

    using a variable for a file handle

    Folks, You can save yourself days of frustration if you ever have to do this. I finally found this obscure page which talks about the problem (not in a regular but extended GOOGLE search): http://mail-archives.apache.org/mod_mbox/perl-modperl/200003.mbox/...
  7. jpasquini

    using a variable for a file handle

    Hi All, Has anyone ever tried to use a variable for a file handle, as in: OPEN ($file, "/home/working/logname" ) where $file changes, meaning the handle can be 1, 2, 3, 4, 5 depending on what the variable $file is. I have a program which opens a tailed log file, and works perfectly well...
  8. jpasquini

    detecting when a file appears

    Sorry...there is a batch program that is system called that writes to the logfile while it is running, and when it is finished it renames the log by adding "_complete" to the end. The program scrolls the logfile on the screen as the batch prog is running, then when it finds the file ending in...
  9. jpasquini

    detecting when a file appears

    ############################################## ## This subroutine creates a scrolled window ## which displays the contents of a log file ## as it is being written ##--------------------------------------------- open (LOG, "tail -f -n 25 ${batch_script_directory}LOG_$_[0]|") or die "Tail...
  10. jpasquini

    detecting when a file appears

    ************************ * EXCELLENT * ************************ $mw-> update; in the loop That did the trick! It checks the IF line. As on Who Wants to be a Millionaire, "It's always easy if you know the answers". kudos all around.
  11. jpasquini

    detecting when a file appears

    The problem is that the IF code never gets checked. Perl TK hangs on the line MainLoop; and waits for you to click a button or object. If you put the IF code in the program, it will only check one time through, then go to MainLoop and wait for you to type or click something before budging.
  12. jpasquini

    detecting when a file appears

    Has anyone out there seen an example of having a block of code execute when a file is deleted or renamed? Basically I need to do this: if ( -f "file_complete" ) { print "The process is done! Press B to continue\n" } The problem is the way TK works, you have this "MainLoop" line...
  13. jpasquini

    waiting for a process to finish

    Hi All, Has anyone ever ran a program in the background with a system call: $status = system ( "run_program&" ); and then wanted to know when it finished? I have looked at articles on fork, wait, and waitpid, many of these appear to be the same obscure paragraph repeated over and over...
  14. jpasquini

    Displaying live results of a logfile in a window

    Paul, An excellent module. However, we don't have it. Unfortunately every module that doesnt' come with the current purchased version would have to go across reams of desks and rubber stamps. Envision something like getting a bill through Congress.......it's a huge company. I could email up...
  15. jpasquini

    Displaying live results of a logfile in a window

    The verdict has come down that ReadBackwards is a nonstandard module and is to be therefore forever forbidden and shunned. I am no longer allowed to think about ReadBackwards. The command is basically running a bunch of stuff, and then dropping the results line by line into a logfile. "Read...

Part and Inventory Search

Back
Top