Jump to content
Macro Express Forums

If variable??? trying to use if variable to paste an eleven digit number.


Recommended Posts

<VARIABLE SET STRING Option="\x01" Destination="%Value%" Prompt="Enter characters or numgers" Mask="FALSE" OnTop="TRUE" Left="Center" Top="Center" Monitor="0"/>
<VARIABLE MODIFY STRING Option="\x00" Destination="%Value%"/>
<VARIABLE SET INTEGER Option="\x0D" Destination="%Length%" Text_Variable="%Value%"/>
<IF VARIABLE Variable="%Length%" Condition="\x00" Value="11" IgnoreCase="FALSE"/>
<TEXT BOX DISPLAY Title="TRUE!" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang1033{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs20 \"\\f1 %\\f0 Value\\f1 %\\f0 \" is 11 characters long\\f1 \r\n\\par }\r\n" Left="Center" Top="Center" Width="278" Height="200" Monitor="0" OnTop="TRUE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/>
<ELSE/>
<TEXT BOX DISPLAY Title="FALSE!" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang1033{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs20 \"\\f1 %\\f0 Value\\f1 %\\f0 \" is NOT 11 characters long\\f1 \r\n\\par }\r\n" Left="Center" Top="Center" Width="278" Height="200" Monitor="0" OnTop="TRUE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/>
<END IF/>
Variable Set String %Value%: Prompt
Variable Modify String %Value%: Trim
Variable Set Integer %Length% to the length of variable %Value%
If Variable %Length% Equals "11"
  Text Box Display: TRUE!
Else
  Text Box Display: FALSE!
End If

 

Link to comment
Share on other sites

WOW, Thank you so much Acantor! So it is possible! I am currently trying to modify the macro you created however I was not successful to make it happen. My idea is like, once I copied a text from a notepad and that text would contain 11 numbers, my macro would automatically choose the 11 numbers to paste it to a certain box, I was trying to make my work easier by making this macro. " for example I copied a text which contains 11 numbers.

(((( This is a sample text that I would copy, for example I have here 123456789 numbers and the next one is 11111111111 which contains 11 numbers, the macro I want would then  clipboard paste it to a certain box and not on a text box))))

I attached here your macro that I have modified, and on the next post I will give a sample macro for the system we use at work so you can understand better my idea. haha I really hope someone could help me, it would help me to make my work easier than usual. THANK YOU SO MUCH.

variable1.mxe

Link to comment
Share on other sites

so here's an example to our system. this is how my logic looks like, if I tried using my macro it would be successful and would only be working up to line 46 seen on codes below and on the sample .mex that I attached. however what I want is to put the 11 numbers that is included to this text 11111111111 copied from the notepad and then to the system shown on the picture. I want it to put specifically to the box which is Claim Control #. so if you can see on my macro created, on the line 46, this whole text that I copied, will be pasted on the big white box. then it should reset back again to inquirer box up to the USER box by using the <TAB>  and then from the user tab I used (ARROW DOWN> since the <TAB> key wont work on the user box to go to the claim number box, the <ARROW DOWN> will be on  line 92. then followed by the paste clipboard to paste the 11 numbers. However it was not successful, I hope anyone could understand the idea. Please help me out I would really really appreciate it. I'm a newbie and creating macro is very interesting and I really want to learn and master it.

 

<LOCK PLAYER Wait="TRUE"/>
<MULTIPLE CHOICE MENU Style="\x00" Result="\x00" Dest="%Badjoker%" Title="FGS1Tickler Macro Board" Prompt="Select Desired Note" Options="Claim Paid - Adjustment\r\n" Left="Center" Top="Center" Monitor="0" Width="582" Height="424" OnTop="FALSE" Columns="Auto"/>
<IF VARIABLE Variable="%Badjoker%" Condition="\x00" Value="A" IgnoreCase="FALSE"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>P<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>C<SHIFT><ARROW DOWN><TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>S<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>F<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>P<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>A<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>C<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>R<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="mm'" Flags="\x32" Date="12/7/2018 9:47:38 AM" Month_Offset="0" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="dd" Flags="\x32" Date="12/7/2018 10:09:12 AM" Day_Offset="1" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="yy" Flags="\x30" Date="12/7/2018 10:10:25 AM" Year_Offset="0" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>F<SHIFT>G<SHIFT>S1"/>
<DELAY Flags="\x01" Time="0.05"/>
<TYPE CLIPBOARD TEXT Ignore_CRLF="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<VARIABLE SET INTEGER Option="\x0D" Destination="%Length%" Text_Variable="%Value%"/>
<IF VARIABLE Variable="%Length%" Condition="\x00" Value="11" IgnoreCase="FALSE"/>
<CLIPBOARD COPY/>
<ELSE/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<ARROW DOWN>"/>
<CLIPBOARD PASTE/>
<END IF/>
<END IF/>
 

 

 

macro.PNG

variable1.mxe

Link to comment
Share on other sites

<LOCK PLAYER Wait="TRUE"/>
<MULTIPLE CHOICE MENU Style="\x00" Result="\x00" Dest="%Badjoker%" Title="FGS1Tickler Macro Board" Prompt="Select Desired Note" Options="Claim Paid - Adjustment\r\n" Left="Center" Top="Center" Monitor="0" Width="582" Height="424" OnTop="FALSE" Columns="Auto"/>
<IF VARIABLE Variable="%Badjoker%" Condition="\x00" Value="A" IgnoreCase="FALSE"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>P<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>C<SHIFT><ARROW DOWN><TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>S<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>F<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>P<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>A<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>C<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>R<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="mm'" Flags="\x32" Date="12/7/2018 9:47:38 AM" Month_Offset="0" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="dd" Flags="\x32" Date="12/7/2018 10:09:12 AM" Day_Offset="1" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<DATE/TIME Format="yy" Flags="\x30" Date="12/7/2018 10:10:25 AM" Year_Offset="0" IsDateVar="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<SHIFT>F<SHIFT>G<SHIFT>S1"/>
<DELAY Flags="\x01" Time="0.05"/>
<TYPE CLIPBOARD TEXT Ignore_CRLF="FALSE"/>
<DELAY Flags="\x01" Time="0.05"/>
<VARIABLE SET INTEGER Option="\x0D" Destination="%Length%" Text_Variable="%Value%"/>
<IF VARIABLE Variable="%Length%" Condition="\x00" Value="11" IgnoreCase="FALSE"/>
<CLIPBOARD COPY/>
<ELSE/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<TAB>"/>
<DELAY Flags="\x01" Time="0.05"/>
<TEXT TYPE Action="0" Text="<ARROW DOWN>"/>
<CLIPBOARD PASTE/>
<END IF/>
<END IF/>

this is the codes, I'm sorry

Link to comment
Share on other sites


 P C S F P A  C R      031519  FGS1so here's an example to our system. this is how my logic looks like, if I tried using my macro it would be successful and would only be working up to line 46 seen on codes below and on the sample .mex that I attached. however what I want is to put the 11 numbers that is included to this text 11111111111 copied from the notepad and then to the system shown on the picture. I want it to put specifically to the box which is Claim Control #. so if you can see on my macro created, on the line 46, this whole text that I copied, will be pasted on the big white box. then it should reset back again to inquirer box up to the USER box by using the    and then from the user tab I used (ARROW DOWN> since the   key wont work on the user box to go to the claim number box, the
 will be on  line 92. then followed by the paste clipboard to paste the 11 numbers. However it was not successful, I hope anyone could understand the idea. Please help me out I would really really appreciate it. I'm a newbie and creating macro is very interesting and I really want to learn and master it.

 

this is how it will look like if used on the noted pad or any pad

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...