Need equivalent to Char() string function

HCC

Member
Hi, does macrodroid have an equivalent to the (Visual Basic 6)
Char() function ?

example:

For a = 48 To 57
Print Chr(a)
Next
the result is: ' ===> 0 1 2 3 4 5 6 7 8 9

or:

a = 48: myString = Chr(a): Print myString ' ====> 0
a = 57: myString = Chr(a): Print myString ' ====> 9
a = 97: myString = Chr(a): Print myString ' ====> a
a = 65: myString = Chr(a): Print myString ' ====> A

In macrodroid I want to make a loop from 97 to 100 (with macrodroid integer variable), set integer variable to [value +1]
in order to get an output string variable like
a
b
c
d

How can I do this?
 

Dm114

Well-known member
Hi, does macrodroid have an equivalent to the (Visual Basic 6)
Char() function ?

example:

For a = 48 To 57
Print Chr(a)
Next
the result is: ' ===> 0 1 2 3 4 5 6 7 8 9

or:

a = 48: myString = Chr(a): Print myString ' ====> 0
a = 57: myString = Chr(a): Print myString ' ====> 9
a = 97: myString = Chr(a): Print myString ' ====> a
a = 65: myString = Chr(a): Print myString ' ====> A

In macrodroid I want to make a loop from 97 to 100 (with macrodroid integer variable), set integer variable to [value +1]
in order to get an output string variable like
a
b
c
d

How can I do this?
20240311_072102.jpg
 

MacroDroidDev

Administrator
Staff member
You can use text manipulation action with the substring option.

If you had the following string: ABCDEFG

to get the C character you would do

substring (2,3)
 

Dm114

Well-known member
You can use text manipulation action with the substring option.

If you had the following string: ABCDEFG

to get the C character you would do

substring (2,3)
I think @HCC wants to get the string character corresponding to an ascii number, not a substring.

Unless I misunderstood...
 
Top