topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • February 16, 2020, 01:22 PM
  • Proudly celebrating 14 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Xavi_8m [ switch to compact view ]

Pages: [1]
1
Find And Run Robot / Use of Variables inside Aliases
« on: April 26, 2019, 06:39 AM »
Hello there, new user here!

I've gotta say that I am having an absolute blast fiddling around with Find And Run Robot. I adore how amazingly powerful it can be with a footprint of 3MBytes. I'm also digging big time that it's not "indexed", minimizing the footprint even further. I'm most definitely gonna start using it as my main launcher, waving goodbye to heavier alternatives.

Now I'll cut to the chase: I'm having an issue while attempting to use variables inside Aliases, and I was hoping someone could lend me a hand.

First of all, I'll say that I have a programming background, and I've read the Alias and Variables Help pages thoroughly, so I am aware of how variables are to be used (at least at a basic level). For example, I know that if a variable is defined as:

[myVar]
hundred=100

Then, said variable can be accessed via %uservar.myvar.hundred% from inside the Alias. I've created a test alias to illustrate how this would work. Here's the test configuration:

TestAlias.jpg
Fig1. Setup of an Alias that uses a raw variable

And here's how the test triggers the variable:

TestAlias2.jpg
Fig2. Using the previous Alias. Please, note that the "hundred" string is actually
not necessary, it could've been any other string (or even empty)

So far so good. No issues here. My problem comes when I want to use a regular expression captured group to access a variable name. Here's where things get dirty:

TestAlias3.jpg
Fig3. Setup of an Alias that uses a regex capture group as a variable

And here's where the problem that appears:the Alias does not seem to resolve the variable name (uservar.myvar.$$1) properly. When I try to use the alias from the launcher I get this error message of sorts:

TestAlias4.jpg
Fig4. Using the regex'd Alias

My question being.... why is this not working!?!?!?!?!?

I am pretty sure that I know what the problem is in here: most likely, the Alias parser is looking for actual variable uservar.myvar.$$1, with the dollar symbols and all, which of course does not exist. But then comes the UI print function, which does indeed resolve the $$1 into "hundred" and thus spits the error message we see in Figure 4:

MISSINGUSERVAR:myvar.hundred

I'm gonna guess that I'm asking too deep of a question, but I'll cross my fingers and hope for an available quick fix for this issue. Maybe using 3 dollar symbols instead of 2? Putting it upside down and shaking it?  ;D

Thank you very much for such an amazing piece of software, and I'll see you around,
Cheers.



Pages: [1]