Subj : Re: Varrible assignments
To   : Digital Man
From : Finnigann
Date : Sat Sep 08 2007 11:18 pm

-=> With regards to the social ramifications;
    Digital Man wrote to Finnigann <=-

DM>   Re: Varrible assignments
DM>   By: Finnigann to All on Sat Sep 08 2007 10:42 am

>
>
>   How would I get the file extention into a varrible?
>
>   [Example]
>
>   Contest.845  file name,
>            ^^
>   which would change from week to week as part of the extention (last
>   two digits are the week of the year).
>
>   If your reply doesn't show how to get the file name into a varrible,
>   how might that be done, too.
>
>   advThanksance.
>
>   In the  I'm-gonna-hate-myself-in-the-morning dept...I downloaded Jas'
>   oneliner program (with .SRC) and am actually learning from it. Thanks.

DM> If the filename portion is fixed-length (e.g. always "Contest", 7
DM> chars), then the following would work:

DM> str extension
DM> copy extension filename
DM> shift_str extension 7     # filename portion is always 7 chars


Would the dot count as a space?

contest.845
12345678


DM> str extension           # defining varrible 'extention' as a string
DM> copy extension filename # I'm gonna have to hard code the filename
                            # right?
DM> shift_str extension 7   # filename portion is always 7 chars


The filename (CONTEST) stays the same, will wild cards work in BAJA for
the extention?

  copy extention contest.???  # Making sure that there are never more
                              # than one file name in the work dir.



  _   _   _   _   _   _   _   _   _
 / \ / \ / \ / \ / \ / \ / \ / \ / \
( F | i | n | n | i | g | a | n | n )
 \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/


... Lean left. Nah, your OTHER left! - Crow as barber
--- MultiMail/Win32 v0.47
� Synchronet � Bits-N-Bytes - bnb.dtdns.net / bnb.synchro.net