Search found 327 matches

by hagchr
Thu Jun 04, 2015 2:12 pm
Forum: Technical / Scripting
Topic: Naming buttons in Dialog with array info
Replies: 7
Views: 4634

Re: Naming buttons in Dialog with array info

In this case SetDialogProperty> needs to come before ShowDialog>. (The comma in Show>Dialog1, will make the dialog modal and execution will halt until the dialog is closed, ie it will not reach the SetDialogProperty until it is too late in your example).
by hagchr
Thu Jun 04, 2015 12:20 pm
Forum: Technical / Scripting
Topic: Naming buttons in Dialog with array info
Replies: 7
Views: 4634

Re: Naming buttons in Dialog with array info

Caption is just a parameter so very easy to change (eg use SetDialogProperty>) For the buttons, one way could be to generate the buttons dynamically based on the Excel file, another way (easier) could be to create the 40 buttons in your dialog (with proper placement etc) and then you read the excel ...
by hagchr
Thu Jun 04, 2015 11:51 am
Forum: Technical / Scripting
Topic: Naming buttons in Dialog with array info
Replies: 7
Views: 4634

Re: Naming buttons in Dialog with array info

Wouldn't it be possible to change the object names if you put the dialog code into a label and then use LabeltoVar> to get it into a variable, then do the adjustments (buttons, names, captions etc) through some string work and finally use IncludefromVar> and Show> to get the modified dialog? (ie cha...
by hagchr
Wed May 27, 2015 8:36 am
Forum: Technical / Scripting
Topic: hotkeys not working latest version - official
Replies: 6
Views: 5067

Re: hotkeys not working latest version - official

Hi, Try to use Message>xx instead, then you should see the text (Send>xx will just send xx to the active window which will not work in your example).
by hagchr
Sat Apr 11, 2015 10:47 am
Forum: Technical / Scripting
Topic: Modify Field In CSV File
Replies: 1
Views: 1975

Re: Modify Field In CSV File

Hi, this would be a simple way to do it. Hope it helps. //For illustration, data is read from label LabelToVar>List,StrData,1,0,{"*/"} //To read data from file use "ReadFile" instead and comment out / delete the "LabelToVar" above //ReadFile>C:\...\datafile.csv,strData Separate>strData,%CRLF%,strRec...
by hagchr
Tue Mar 31, 2015 10:59 am
Forum: Scripts and Tips
Topic: "Pass" Array to SRT
Replies: 2
Views: 8744

Re: "Pass" Array to SRT

Hi, thanks for the reply. I modified the original code to your test string and changed the name to My_ARR and it still works fine. Key if you use this method is to keep the two regexes - one at the beginning of the SRT and one at the end which gives the unresolved array names, ie Gosub>calc,"My_ARR"...
by hagchr
Fri Jan 30, 2015 3:37 pm
Forum: Technical / Scripting
Topic: xlsetcell as an array...
Replies: 2
Views: 2167

Re: xlsetcell as an array...

Hi, in VBS / Excel there is a range property - FormulaArray - that can be used to define an array formula, in the case below placing it in cell "E8" in "Sheet1" in "test.xlsx". The original formula had to be modified slightly to avoid confusion with the quotes. Hope if helps. VBSTART Sub updExcel Se...
by hagchr
Thu Jan 15, 2015 5:52 pm
Forum: Technical / Scripting
Topic: Read and Write StringGrid Cell?
Replies: 4
Views: 3986

Re: Read and Write StringGrid Cell?

Thanks JRL for opening my eyes for StringGrid. I am now trying to figure out the various parameters. Some implementations of StringGrid seem to have a Cells[row][column] kind of property to easily access individual elements. I think that is what you suggested and also seems to be on the list. In the...
by hagchr
Sun Dec 14, 2014 9:37 am
Forum: Beginners
Topic: variable inside variable
Replies: 2
Views: 3467

Re: variable inside variable

Sorry, was too fast, in this case you can simplify it more.

Code: Select all

Let>personaje=1
Let>xdelpersonaje[1]=340
Let>x=xdelpersonaje[%personaje%]
by hagchr
Sun Dec 14, 2014 9:27 am
Forum: Beginners
Topic: variable inside variable
Replies: 2
Views: 3467

Re: variable inside variable

Hi, I guess you want to do this:

Code: Select all

Let>personaje=1
Let>xdelpersonaje[1]=340

Let>tmp=xdelpersonaje[%personaje%]
Let>x=%tmp%
by hagchr
Thu Dec 11, 2014 2:33 pm
Forum: Technical / Scripting
Topic: XML to CSV convertion
Replies: 5
Views: 4412

Re: XML to CSV convertion

An alternative approach for anyone interested in RegEx. It is probably an over-kill for smaller data sets but could well be worth it for larger ones (seconds instead of minutes in terms of runtime). It is based on the info provided in the post so would possibly have to be adjusted if the actual file...
by hagchr
Mon Dec 08, 2014 4:28 pm
Forum: Technical / Scripting
Topic: Watch List issue with long lines - was Reading ini files..
Replies: 2
Views: 2297

Re: Watch List issue with long lines - was Reading ini files

Sorry no intention to mix the posts. I get the issue from time to time when debugging but since the code works fine I just thought it was some kind of display problem on my side. just got the impression the previous poster had a similar issue with a blank line.
by hagchr
Mon Dec 08, 2014 4:07 pm
Forum: Technical / Scripting
Topic: Watch List issue with long lines - was Reading ini files..
Replies: 2
Views: 2297

Watch List issue with long lines - was Reading ini files..

Hi, not sure if this is the same thing but the following code runs well but when I step it through line by line then the extract line looks empty (cannot find resTag anywhere). However, if I copy the line to NotePad the extract is there ok. IECreate>IE[0] IEShowIE>IE[0],1 Let>URL0=http://bors.affars...
by hagchr
Fri Nov 28, 2014 5:53 pm
Forum: Technical / Scripting
Topic: the boolean operator in a variable
Replies: 5
Views: 4021

Re: the boolean operator in a variable

If one add a step to the first piece of code then it seems to work.

Code: Select all

Let>clip=0
Let>max=10
Let>bool=>

Let>condition=%clip%%bool%%max%
Let>Test={condition}

If>Test=TRUE
 MessageModal>greater
Else
 MessageModal>smaller
EndIf
by hagchr
Mon Nov 10, 2014 3:00 pm
Forum: Technical / Scripting
Topic: Issue with CodeBlock in v14.2
Replies: 7
Views: 4548

Re: Issue with CodeBlock in v14.2

New version works great, many thanks for the update.
Sign up to our newsletter for free automation tips, tricks & discounts