PotterHarry
Members-
Posts
76 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Everything posted by PotterHarry
-
Thanks Samrae...
-
Hope Jeff won't mind me hijacking his thread, but it is kind of relevant ..what programming language is Macro Express under the hood? Is that a daft question. I wouldn't be surprised...!!
-
Hi again.. I can't understand what's happening here. I'm using ME Pro Portable. A selection of my macros write to the registry. On one PC with which I do most of my work, everything works fine. I created all the necessary registry keys on another PC in order to be able to work on that PC. However I'm seeing a lot of errors Eg. Line 7: Debug error: Could not access the specified registry value. With one macro, by elimination, I determined that this error would happen when there was no value set in the registry key. I wrote values to all the keys referenced in that macro and it now works fine. Now I have another macro with the same issue. This time there is a value in there "B" so I'm stumped. I'm running in administrator mode. If I disable just that one line then all the other values load correctly. The variable is correctly defined. Wonder what's going on? Thanks.
-
Retrieving array variables from Excel
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thanks Samrae (and Cory for the guidance) I have the whole thing working now. The mistake I made was saving the .csv as UTF-8. The other option got rid of the squiggle... Thank you !!! -
Retrieving array variables from Excel
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
I have had a go at this using my two columns of data saved as a .csv. I am seemingly getting the correct pairs of values (giving me hope!) apart from at the very first iteration I'm getting this odd symbol ... 0 I placed a text box between Ascii file begin process and ascii file end process %T[1]% %T[2]% %T[3]% %T[4]% %T[5]% %T[6]% %T[7]% %T[8]% On running it I'm seeing 0 1 -1 0 0 1 -1 1 They are all the correct values for the start of the series. I guess I just need to trim that first value back to a 0 assuming the garbled stuff will be the same with different .csv files? -
Retrieving array variables from Excel
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
. -
Retrieving array variables from Excel
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thank you very much Cory. Here is the file... two columns ready.xlsm -
Hi again! I have been experimenting with VBA in Excel. I have succeeded in creating two columns of values ( representing mouse coordinates) which I have stored in an array variable. What is the best method of getting that variable over to ME Pro? I assume registry write is an option. Will the format of the array be compatible? Excel is very good at doing what I'm trying to achieve (relative position of pixels) but I always fear that solutions that would be obvious to an experienced programmer would be lost on me! Thanks...
-
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
That did it Cory..thanks very much. -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Text File End Process Variable Save: Save All Variables Mouse Move: 705, 641 Relative to Screen Mouse Left Button Down Variable Set Integer %REPCOUNTER[1]% to 750 Repeat Start (Repeat %REPCOUNTER[1]% times) Mouse Move: %XCOORD[%REPCOUNTER%]%, %YCOORD[%REPCOUNTER%]% Relative to Screen Delay: 0.1 seconds End Repeat Mouse Left Button Up Text Box Display: My mouse coordinates are now recording successfully. In the above code I'm seeing variable is the wrong type error on this line: Mouse Move: %XCOORD[%REPCOUNTER%]%, %YCOORD[%REPCOUNTER%]% Relative to Screen. They are all integer variables and they are defined. Is my syntax incorrect? XCOORD and YCOORD are array variables with 750 elements. Thanks. -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Elegant is not the word...it works!! Thanks. -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Hi again. Thanks Cory and rberq for your leads .. in the end I gave up on length of string in favour of sampling the first character. This macro does work very well, but the use of "If variable %LOOP[1]%" in lines 23-27 seems rather inelegant. Is there a more efficient way of passing these values to a predefined array? STRIP VALUES_2.mex MouseRecorderPro2.txt -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Hi again. Of course I am learning all the time (as I'm sure we all are) but in my case evidently I'm a lot lower down the snakes and ladders board. I do have a working macro now, with some issues. I have used the length of the string to eliminate lines that do not contain x or y. I'll take a look at the split function suggested by Cory later when I get back from work. -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
I have made some progress .. 1) How do I "pass" the values to an integer array variable 2) How can i get it to ignore the lines that start with a 5 3) What if the length of the number is only 3 digits (this will happen)? Thanks!! STRIP VALUES.mex -
How to extract values from a script
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thanks both for your help .. I'll give it a try later. -
Hi... below is a script section copied from Notepad. What do I have to do to extract the values of X and Y into integer array variables? **Script version 2.0.2.0** 5 864 1 X:1701 Y:580 1 X:1700 Y:580 1 X:1692 Y:574 1 X:1687 Y:572 5 32 1 X:1678 Y:568 1 X:1664 Y:563 1 X:1648 Y:559 1 X:1636 Y:555 5 32 1 X:1621 Y:549 1 X:1603 Y:539 1 X:1555 Y:515 1 X:1523 Y:496 5 32 1 X:1484 Y:477 1 X:1440 Y:462 1 X:1391 Y:446 1 X:1286 Y:421 I will only waste hours if not days if I don't ask
-
Writing values to registry. Best approach?
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thanks rberq .. I have 44 fields that save quite nicely in the registry to individual keys as text strings, with separators. Must research environment variables. It seems that everything I do is eventually superseded by a more elegant solution! -
Writing values to registry. Best approach?
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thanks Cory .. My first attempt worked!! -
Hi all I have sampled a range of screen positions to an array variable %incr[1]%, %incr[2]%. These are integer variables. Currently I am writing all these many variables to individual registry keys. How would it be possible (if indeed it is) to store this list of values in a single key? Join variable seems to be Text based, and these values are integer. I'd appreciate a steer in the right direction. Thank you !!
-
Invisible registry item
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
I've got it now.. Line 5: should read If registry: key etc. and lines 23 & 24 were missing a backslash after drawingmacro1 and drawingmacro2. Works flawlessly now. <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\drawingmacro1\\" Destination="%DRAWINGMACRO[1]%"/> Thanks for your invaluable help. Simple things do throw me!! -
Invisible registry item
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Thanks for taking the time to do this drawingmacro1 appears on my registry in the screenshot on my first post. I've attached the registry export.. ME Reg [Cory].reg -
Invisible registry item
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
I removed it and it made no difference. -
Invisible registry item
PotterHarry replied to PotterHarry's topic in Macro Express and Macro Express Pro
Hi Cory Thanks your reply. I like the pizza delivery guy analogy.. I have attached a sample macro, and a jpeg of my registry keys and the textbox display output (the last one). At runtime lines 5-7 do not cause the textbox to display as if drawingmacro variable does not exist. Clearly from my image of regedit it does. This macro that I have included here refuses to read the last two variables as if they don't exist. The values are text strings stored in the registry at an earlier run-time. The odd thing is, if i copy and paste that same code to a later part of my main macro, then it works ?!? It's as if those two variables are not accessible UNLESS they are stored and retrieved within the same macro activation. Is this normal windows behaviour? Thanks PH REGISTRYTEST.mex -
Hi I'm writing both numeric and text string values to the registry. ALL these values are there because I can see them using Regedit. (Ignore READ as this is copied from another section of the code) The last two values which are in fact text strings are not shown if i try to use a text box to list them. They are not "0" they are simply absent. If I duplicate the same section of code later in the program everything is fine and all the values get displayed. I put this line at the very start to test if the registry entry was visible: <IF REGISTRY Key="FALSE" Exists="TRUE" Path="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\drawingmacro1"/> Result: It's invisible.(It's a text string) I then used <IF REGISTRY Key="FALSE" Exists="TRUE" Path="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor1"/> This time it displays (Within a text box) This is a numeric value. I'm running the macro from a portable version with admin privileges. Does anyone have an idea what could be happening? Thanks!! <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\p" Destination="%P%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor1" Destination="%PIXCOR[1]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor2" Destination="%PIXCOR[2]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor3" Destination="%PIXCOR[3]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor4" Destination="%PIXCOR[4]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor5" Destination="%PIXCOR[5]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor6" Destination="%PIXCOR[6]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor7" Destination="%PIXCOR[7]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\pixcor8" Destination="%PIXCOR[8]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\avoid1" Destination="%AVOID[1]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\avoid2" Destination="%AVOID[2]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\avoid3" Destination="%AVOID[3]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\avoid4" Destination="%AVOID[4]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\drawingmacro1" Destination="%DRAWINGMACRO[1]%"/> <READ REGISTRY VALUE Key="HKEY_CURRENT_USER\\SOFTWARE\\macroexpress\\drawingmacro2" Destination="%DRAWINGMACRO[2]%"/> <TEXT BOX DISPLAY Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang2057{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs16 %PIXCOR[1]%\r\n\\par %PIXCOR[2]%\r\n\\par %PIXCOR[3]%\r\n\\par %PIXCOR[4]%\r\n\\par %PIXCOR[5]%\r\n\\par %PIXCOR[6]%\r\n\\par %PIXCOR[7]%\r\n\\par %PIXCOR[8]%\r\n\\par %AVOID[1]%\r\n\\par %AVOID[2]%\r\n\\par %AVOID[3]%\r\n\\par %AVOID[4]%\r\n\\par %DRAWINGMACRO[1]%\r\n\\par %DRAWINGMACRO[2]%\r\n\\par \r\n\\par \\f1 \r\n\\par }\r\n" Left="821" Top="420" Width="280" Height="354" Monitor="0" OnTop="TRUE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/>