Jump to content
Macro Express Forums

chappyware

Members
  • Posts

    8
  • Joined

  • Last visited

chappyware's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. A HA ! I had the IF VARIABLE - BREAK in the wrong spot. This works perfectly !! Creates T[1]=a to T[26]=z <VARIABLE SET INTEGER Option="\x00" Destination="%counter%" Value="1"/> <TEXT FILE BEGIN PROCESS Filename="C:\\alpha.txt" Start_Record="1" Process_All="TRUE" Records="26" Variable="%T[%counter%]%"/> <VARIABLE MODIFY INTEGER Option="\x07" Destination="%counter%"/> <IF VARIABLE Variable="%counter%" Condition="\x03" Value="26" IgnoreCase="FALSE"/> <BREAK/> <END IF/> <VARIABLE SET STRING Option="\x03" Destination="%T[%counter%]%" Filename="c:\\alpha.txt" Strip="FALSE"/> <TEXT FILE END PROCESS/>
  2. I'm ALMOST there. My yext file has 26 lines-each line is one letter of the alphabet (a b c d e etc). This does what I want it to do except I get a 27th element in my array equal to the first ('a'). <VARIABLE SET INTEGER Option="\x00" Destination="%counter%" Value="1"/> <TEXT FILE BEGIN PROCESS Filename="C:\\alpha.txt" Start_Record="1" Process_All="TRUE" Records="26" Variable="%T[%counter%]%"/> <VARIABLE MODIFY INTEGER Option="\x07" Destination="%counter%"/> <VARIABLE SET STRING Option="\x03" Destination="%T[%counter%]%" Filename="c:\\alpha.txt" Strip="FALSE"/> <TEXT FILE END PROCESS/> How do I get out after counter = 26? I tried a IF Variable-counter>26 BREAK END IF to no avail. any suggestions?????
  3. How would I fill %STRING% from a text file instead of defining it at the outset.
  4. I JUST upgraded to MEP and am trying to fill an array from a text file(ArrayTest.txt). I created a 26 line text file with notepad where each line is a letter of the alphabet (a is first [1], z is last [26]. I'm really having a hard time doing this. Can someone give me a SIMPLE explanation? I seem to be able to use the TEXT BEGIN PROCESS and END PROCESS to grab the right file but I only get the last line. I think an explanation of setting up the array would be helpful. I'm missing something. I follow the example and set the TEXT BEGIN PROCESS by giving the right file name and start with record 1 and Variable to receive results set to %T[1]%. Then I put in an TEXT END PROCESS. I run it in Test Mode and look at the variables. All I see is T[1] is z. What am I doing wrong? It looks like T[1] just keeps getting over-written instead of incrementing (T[1],T[2],T[3]...T[26]). I guess I need some kind of processing in the middle. Maybe copy each T[1] to X[1] then X[2] but how to do that? Thanks for whatever help you can give.
  5. I think the answer is in another post about TEXT BEGIN and ASCII CHAR. I'll figure this one out on my own.
  6. I'm new to ME variables so please don't jump on me if this is a stupid question. I have a text file with each line being a person's name. I want to use a macro to type that name into a application I use. I know how to do that for a literal but reading up I think the VARIABLE FROM FILE reads in the whole file as a single variable. 1. Is that assumption true? 2. If so, how do I get T1,T2,T3,T4...T99 to each be a name from the sequence? There is a CR after each name. ANY help would be greatly appreciated. I have the rest of the macro done but I have no idea how to change the value of the variable or how to assign each line to a new variable (I suppose redefining T1 with a new name would be more efficient-can that be done?????) Thank yo SO much for any assistance. Jan
  7. I'm not real sophisticated and don't write scripts. I have chopped long MP3 files into many smaller units with names like FILE 1.mp3, file 2.mp3 etc. I need to insert a zero in fron of the number and I have a macro that does that once I've done the left click on the file in windows explorer and selected RENAME. There are MANY files and I'd like to auomate the left click-select RENAME part but I can't get it to work. Is there an easy way, without knowing how to write a script, that I could accomplish this? Even better, can I just put it in front of my macro to insert the zero?? Thanks for any help you can give.
×
×
  • Create New...