Unify script language

Ideas for new features & functions

Moderators: Dorian (MJT support), JRL

Post Reply
durexlw
Newbie
Posts: 18
Joined: Mon Mar 17, 2008 1:19 pm

Unify script language

Post by durexlw » Mon Mar 17, 2008 1:58 pm

Subject: code scripts in a VBA-like way

I love what Macro Scheduler can do, I love it's applications, it's possibilities, how it's setup, it's debugger capacities, the functions, ...

I believe the coding can be faster, though. In my experience the IDE is rather slow if I compare it to other IDE's and their language.
The same goes for other Macro proggy's I've tested so far (Automation Anywhere and Macro Express), so you guys could really market with a fast programming language.

What I'm noticing is that for one: VBA is integrated and also: alot of people code in VBA.

Since the VBA parcer is already implemented, it would seem like a good idea to redesign the IDE, so we can write script code in a VBA-like code entirely.

To give a few examples:
--> Me personally, I don't like the idea of having to write 'LET>' any time I want to do something with a variable
--> Having no code indentations can make long code very painful to overlook and understand.
--> To my knowlegde, there is no inline possibilities. So if I need to know the length of a string, use that length in an 'If'-structure, I need to store the length of my string in a temp variable, before I can use it... things like this tend to become confusing as well as slow.
--> ...

On the other hand:
--> I don't see why variables couldn't be a simple line without 'Let>' in front of it
--> Subroutines should be possible, it's just a matter of parsing them
--> Inline expressions same thing: just a matter of parsing them
--> You could even go as crazy as to allow modules be imported and used... not many of your competitors will be able to put that on their website, don't you think?

In one line:
I very much believe the VBA-code and the Scripting-code could be one single thing.

I'm sure you guys can come up with more impressive things, but if you were to make an "msched" object, code like this would be a breeze:

Code: Select all

Dim iMatch as Integer

iMatch = mshed.ImageRec.CompareBitmaps "d:\required_screen.bmp", "d:\current_screen.bmp"

If iMatch = 100 then
  Set xlApp = CreateObject("Excel.Application")
  xlApp.visible = true
Else
   MsgBox "It matches for " & iMatch & " %... that's not enough mate"
End If
No more differentiating between VBA and the scripting language, no more slow coding, no more use to learn a new language to make scripts, more readable scripts, more opportunities to make your IDE user friendly: intellisense, code-collapsing, code-indentation, procedures, functions, modules, Case-structures, ...

User avatar
Marcus Tettmar
Site Admin
Posts: 7380
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Mon Mar 17, 2008 2:41 pm

"I love what Macro Scheduler can do, I love it's applications, it's possibilities, how it's setup, it's debugger capacities, the functions, ..."
Glad to head it.
"In my experience the IDE is rather slow if I compare it to other IDE's and their language. "
You mean the script editor? I'm not aware of any performance issues.
"> Me personally, I don't like the idea of having to write
LET>' any time I want to do something with a variable "
That's a personal thing. Others may disagree. Difficult to offer something that everyone likes.
"-> Having no code indentations can make long code very painful to overlook and understand. "
No code indentations? Press TAB. Also Edit/Block Indent - Edit/Block Unindent
"To my knowlegde, there is no inline possibilities. So if I need to know the length of a string, use that length in an 'If'-structure, I need to store the length of my"
If>{length(%mystring%)}

Endif
"I don't see why variables couldn't be a simple line without 'Let>' in front of it "
Personal. Others may disagree with you.
"Subroutines should be possible, it's just a matter of parsing them "
Subroutes ARE possible. Use SRT/END blocks and GoSub etc.
"Inline expressions same thing: just a matter of parsing them"
Use complex expressions.
"You could even go as crazy as to allow modules be imported and used... not"
We already do. You can write custom DLLs for use within Macro Scheduler and the Imports method lets you create native looking functions. Some plugins are available here:

http://www.mjtnet.com/plugins.htm

You can also use Include> so people can offer script modules.
"I very much believe the VBA-code and the Scripting-code could be one single thing."
I think you mean VBScript. It was actually a conscious decision not to do this. Reason is most of our customers are NOT programmers. MacroScript is designed to be simple for people who are not programmers. I think we'd put many of our customers off if the syntax became more VB like. VBScript is there for those that want the extra flexibility and power. You have the benefit of both worlds.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts