01-14-13 07:27 AM
712 ... 34567 ...
tools
  1. gbsn's Avatar
    One UI bug, esckey does work as a cancel if there are modifications on the current page, but, when highlighting something, say in the edit shortcut screen, and you press esckey, it exits the shortcut editor, instead of canceling the highlighting.

    For && and ||, I can't even get get if0 $suspend==1, or if0 $suspend, to work after setting $suspend in another macro or in a previous if sentence in the same macro.
    This one also doesnt do what is expected, if0 isdefined $suspend && $suspend==1; in an importmacro environment.
    In fact, if0 isdefined $suspend, does not work anymore like it did before the update.

    What i did notice, the if statements are executing after all the other macros. I dont know why, but after the main finishes, SCM stays in the background, then it continues with the suspend, and does the if statement that was skipped.
    10-01-11 07:58 PM
  2. Vijik's Avatar
    One UI bug, esckey does work as a cancel if there are modifications on the current page, but, when highlighting something, say in the edit shortcut screen, and you press esckey, it exits the shortcut editor, instead of canceling the highlighting.

    For && and ||, I can't even get get if0 $suspend==1, or if0 $suspend, to work after setting $suspend in another macro or in a previous if sentence in the same macro.
    This one also doesnt do what is expected, if0 isdefined $suspend && $suspend==1; in an importmacro environment.
    In fact, if0 isdefined $suspend, does not work anymore like it did before the update.

    What i did notice, the if statements are executing after all the other macros. I dont know why, but after the main finishes, SCM stays in the background, then it continues with the suspend, and does the if statement that was skipped.
    'Suspend' is a defined name in macros (one of the macros). Could it be that the variable name should be changed to something not defined as a macro?
    10-01-11 08:03 PM
  3. Vijik's Avatar
    Nice Filescout launchs properly, and works with IsAppRunning and IsAppForeground.
    I haven't been able to break || or &&

    Looks like the only two issues are the restore config from thr Common Config page the first try after clean install, and SetVolume
    I can see the problem with SetVolume.
    It looks like that the BB OS API doesn't work.
    I will remove it in the next rev.
    10-01-11 08:04 PM
  4. TomCanuck's Avatar
    One UI bug, esckey does work as a cancel if there are modifications on the current page, but, when highlighting something, say in the edit shortcut screen, and you press esckey, it exits the shortcut editor, instead of canceling the highlighting.

    For && and ||, I can't even get get if0 $suspend==1, or if0 $suspend, to work after setting $suspend in another macro or in a previous if sentence in the same macro.
    This one also doesnt do what is expected, if0 isdefined $suspend && $suspend==1; in an importmacro environment.
    In fact, if0 isdefined $suspend, does not work anymore like it did before the update.

    What i did notice, the if statements are executing after all the other macros. I dont know why, but after the main finishes, SCM stays in the background, then it continues with the suspend, and does the if statement that was skipped.
    How are you using $suspend?

    Set $suspend=1;
    If0 $suspend==1;
    Then0;
    Vibrate200;
    Else0;
    Ding100;
    EndIf0

    Works. It also works if I use importmacro to call ^ that

    Posted from my CrackBerry at wapforums.crackberry.com

    Update #1
    Macro Name: TET
    Macros:
    Set $suspend=1

    Macro Name: TES
    Macros:
    ImportMacro TET;
    If0 IsDefined $suspend;
    Then0;
    Vibrate200;
    Else0;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    EndIf0;

    Works on 9900/7.0.0.353

    Update #2
    ImportMacro TET;
    If0 IsDefined $suspend && IsAppRunning Messages;
    Then0;
    Vibrate200;
    Else0;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    EndIf0;

    Works,

    ImportMacro TET;
    If0 IsDefined $suspend && $suspend==1;
    Then0;
    Vibrate300;
    Else0;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    EndIf0;

    Works,

    ImportMacro TET;
    If0 IsDefined $suspend || IsAppRunning testtest;
    Then0;
    Vibrate300;
    Else0;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    EndIf0;

    Works,

    ImportMacro TET;
    If0 $suspend==3 || IsAppRunning Messages;
    Then0;
    Vibrate300;
    Else0;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    EndIf0;

    Works

    Update #3
    Fixed a typo in an example above. I was copying before trying, forgot to copy the macro after I'd fixed the missing ;
    Last edited by Juggalo20; 10-01-11 at 08:32 PM.
    10-01-11 08:05 PM
  5. gbsn's Avatar
    set in one macro, used in an importmacro.

    changed name to hold.

    as simple as
    launch options;delay500;
    spkeyap m;delay500;
    navclick;
    set $hold=1;
    importmacro ^fpa;
    esckey;esckey;
    esckey;esckey;

    ^fpa contains:

    keytospkey;
    if0 isdefined $hold;
    then0;
    suspend;
    navmoveup1;
    enterkey;delay5;
    endif0;
    BLABLABLA; <- just menukeys and key pressings

    ---
    The suspend and everything after it happens after the BLABLABLA block. When in fact should take place before since $hold is defined. It worked this way before the update, but doesn't work anymore. Its basically based on my example a few posts ago about using templates to do multiple things depending on the variables set.

    It doesn't work even if i use the if as if0 $hold==1.
    Last edited by gbsn; 10-01-11 at 09:12 PM.
    10-01-11 08:59 PM
  6. TomCanuck's Avatar
    set in one macro, used in an importmacro.

    changed name to hold.

    as simple as
    launch options;delay500;
    spkeyap m;delay500;
    navclick;
    set $hold=1;
    importmacro ^fpa;
    esckey;esckey;
    esckey;esckey;

    ^fpa contains:

    keytospkey;
    if0 isdefined $hold;
    then0;
    suspend;
    navmoveup1;
    enterkey;delay5;
    endif0;

    BLABLABLA; <- just menukeys and key pressings

    ---
    The suspend and everything after it happens after the BLABLABLA block. When in fact should take place before since $hold is defined. It worked this way before the update, but doesn't work anymore. Its basically based on my example a few posts ago about using templates to do multiple things depending on the variables set.

    It doesn't work even if i use the if as if0 $hold==1.
    Weird!

    I added a Led On to make double sure $hold was defined. How can I put this... It skipped the suspend, turned on my LED (showing $hold is defined). Then at the very end of the macro it put suspend, when I lauched SCM to continue after the suspend it re-did the code following the suspend :\ so... I don't even...

    keytospkey;
    if0 $hold==1;
    then0;
    suspend;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    navmoveup1;
    enterkey;delay5;
    Else0;
    Vibrate200;
    endif0;

    Posted from my CrackBerry at wapforums.crackberry.com
    10-01-11 09:15 PM
  7. gbsn's Avatar
    I guess its a problem with the suspend in that case, because with all your previous examples it worked and they dont have a suspend.
    10-01-11 09:23 PM
  8. TomCanuck's Avatar
    I guess its a problem with the suspend in that case, because with all your previous examples it worked and they dont have a suspend.
    Swap suspend with prompt and it works correctly also.

    keytospkey;
    if0 $hold==1;
    then0;
    Prompt Got to Then0. continue?;
    Delay500;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    Ding100;
    navmoveup1;
    enterkey;delay5;
    Else0;
    Vibrate200;
    endif0;

    Posted from my CrackBerry at wapforums.crackberry.com

    Definately suspend...

    keytospkey;
    if0 $hold==1;
    then0;
    Prompt Got to Then0. continue?;
    Delay500;
    Vibrate500;
    Suspend;
    Delay500;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    Ding100;
    navmoveup1;
    enterkey;delay5;
    Else0;
    Vibrate200;
    endif0;

    Skips suspend the first time round, then suspends at the very end. Launching SCM to continue redoes everything after suspend



    Just to be clear, the macro I launch is

    Shortcutkey: Tes
    launch options;delay500;
    spkeyap m;delay500;
    navclick;
    set $hold=1;
    importmacro ^fpa;
    esckey;esckey;
    esckey;esckey;

    Shortcut Keys: ^FPA
    keytospkey;
    if0 $hold==1;
    then0;
    Prompt Got to Then0. continue?;
    Delay500;
    Vibrate500;
    Suspend;
    Delay500;
    SetLedColor r;
    Led On;
    Delay5000;
    Led Off;
    Ding100;
    navmoveup1;
    enterkey;delay5;
    Else0;
    Vibrate200;
    endif0;
    Last edited by Juggalo20; 10-01-11 at 09:45 PM.
    10-01-11 09:35 PM
  9. Vijik's Avatar
    I guess its a problem with the suspend in that case, because with all your previous examples it worked and they dont have a suspend.
    Correct guess.

    I can see in the source code that the code for Suspend macro is broken after Prompt macro was changed lately.

    I will fix it soon.
    Last edited by Vijik; 10-02-11 at 09:41 AM.
    10-02-11 08:47 AM
  10. Vijik's Avatar
    5.8.4.3 is on the beta link.

    - It has a fix for Suspend macro bug.

    - The question and button names for the 'Prompt' macro is changed (let me know if you want to have other button names/question in Prompt macro).

    - HasRadioConnection macro should now return false for 'SOS'.
    10-02-11 09:27 AM
  11. TomCanuck's Avatar
    5.8.4.3 is on the beta link.

    - It has a fix for Suspend macro bug.

    - The question and button names for the 'Prompt' macro is changed (let me know if you want to have other button names/question in Prompt macro).

    - HasRadioConnection macro should now return false for 'SOS'.
    Confirming suspend is fixed. I love the prompt dialog, the continue now option makes it nicer for me to use as an infomation dialog for debugging long macros. Noticed this before, but must say I love it. I'll go for a little drive out of town tomorrow or the next day to give SOS a test.

    Posted from my CrackBerry at wapforums.crackberry.com
    10-02-11 12:34 PM
  12. Vijik's Avatar
    Confirming suspend is fixed. I love the prompt dialog, the continue now option makes it nicer for me to use as an infomation dialog for debugging long macros. Noticed this before, but must say I love it. I'll go for a little drive out of town tomorrow or the next day to give SOS a test.
    'Prompt' macro can also be used as a print out for macros, because it does replace variables with their value if variables are found in its argument:
    Set $var1=2;Prompt var1=$var1; (shows "var1=2")

    You don't need to test it in areas with no coverage. If you start the BB without SIM card in it and turn on Radio in Manage Connections, it will be in SOS mode.

    Posted from my CrackBerry at wapforums.crackberry.com
    10-02-11 12:52 PM
  13. TomCanuck's Avatar
    'Prompt' macro can also be used as a print out for macros, because it does replace variables with their value if variables are found in its argument:
    Set $var1=2;Prompt var1=$var1; (shows "var1=2")

    You don't need to test it in areas with no coverage. If you start the BB without SIM card in it and turn on Radio in Manage Connections, it will be in SOS mode.

    Posted from my CrackBerry at wapforums.crackberry.com
    For sure. I use prompt tons, "Got to ThenX with $var" or "Ended up at ElseX... Wat?". Also confirming SOS has been fixed

    Posted from my CrackBerry at wapforums.crackberry.com
    10-02-11 01:19 PM
  14. TomCanuck's Avatar
    Vijik, the scheduled recurring macro bug I mentioned in that email I sent you still exists in ShortcutMe_Touch 5.9.0.0.

    More testing in progress, probably 1 or 2 updates to this post on the way.

    Posted from my CrackBerry at wapforums.crackberry.com

    Update #1
    Edited... Need more coffee before testing...

    Posted from my CrackBerry at wapforums.crackberry.com

    Update #2
    Is it possible to detect super sneaky apps? There's a terribly annoying bug in an app called iLock, can't write a macro to 100% fix it unless I can IfAppForeground for it though. iLock never ever shows up in the "Switch Application" menu though, so I wouldn't be surprised if it can't be detected. IsAppRunning doesn't work for it either though. It shows up as iLock in the JVM Process List in the engineering screen. The module name listed in "Options -> Device -> Application Management -> iLock" is iLock
    Last edited by Juggalo20; 10-03-11 at 01:53 AM.
    10-02-11 11:27 PM
  15. Vijik's Avatar
    ShortcutMe 5.9 is released for 9350, 9360, 9370, 9810, 9850, 09860, 9900, and 9930

    ShortcutMe 5.6 is released for all other models running OS 4.3+, 5.x, and 6.x

    New in these versions is mainly bug fixed version of all new features added in 5.8.4.0 except the addition of 'IsInPortrait' macro.
    (Thank you for testing and reporting bugs!)

    For the record I repeat the new features here:


    * && and || is now allowed for IF and WHILE macro statement
    Example: If0 $Var1 && IsAppRunning Memopad;Then0; ... ; Else0; ... ;EndIf0;

    * ‘Prompt’ macro accepts variables
    Example: Prompt $Var;

    * ‘Prompt’ macro also allows you to continue with the macros or stop them.

    * Added ‘IsInPortrait’ macro
    Returns TRUE if device is in Portrait mode (and FALSE for Landscape Mode).

    * Added ‘GetUpTime’ macro
    Returns up time in hhmmss format where hh is hour, mm is minutes, and ss is seconds after the device is turned on.

    * Added ‘GetTime’ macro
    Returns time in hhmm format where hh is hour, and mm is minutes of the day.

    * Added ‘GetDay’ and ‘GetMonth’ macros.
    Return format is a 2 digits number

    * Added ‘Sum’, ‘Sub’, ‘Mult’, and ‘Div’ macros
    Result of these math operations is stored in $$Result variable.
    $$Rest variable is set to the rest of the Div operation over 2 numbers.

    Example:
    Set $Var1=3;
    Sum 2, $Var1;
    Prompt $$Result; (5 will be shown).
    Div 7,$Var1;
    Prompt Res:$$Result, Rest:$$Rest; ("Res:2, Rest:1" will be shown)


    * Can launch apps with ’ _’ in their name

    * BB_OS-like exit from Shortcut Settings and Macro Editor page (ESC key = Cancel)
    Last edited by Vijik; 10-03-11 at 04:52 AM.
    10-03-11 04:45 AM
  16. Vijik's Avatar
    Juggalo20, It is not actually a bug. I will discuss that with you by replying that email.

    IsAppRunning uses a BB OS API that is also used by Application Switcher on BlackBerry. So if an app can hide from App Switcher, it can also hide from IsAppRunning macro.
    I will browse the APIs trying to find another way of detecting running apps.
    Last edited by Vijik; 10-08-11 at 11:04 AM.
    10-03-11 04:51 AM
  17. TomCanuck's Avatar
    Darn MMMOOO ... Can make the app super sneaky but still have the same bug for like a year now lol >.< Don't put too much effort into it, I've lived with it this long and it's not something that'll be needed often anyways. Just figured it couldn't hurt to ask, incase you had a rough idea off the top of your head.

    Posted from my CrackBerry at wapforums.crackberry.com
    10-03-11 05:01 AM
  18. TomCanuck's Avatar
    I notice feature reqs seem to end up in the macro thread more often than not. But I'm guessing this might be a better spot. Correct me if I'm wrong. Annnyways, I was kinda thinking, of an comment setup. Like
    /* comment */, or even just a prefex to ignore an single command. Like -Ding100 wouldn't actually Ding. I like to think I'm up to speed on what's available in SCM, but I did join the party late so if I missed this somewhere in the like 700 posts in the macro thread and the couple other SCM threads ... Sorry

    Posted from my CrackBerry at wapforums.crackberry.com

    Edit #1
    Or would that put too much strain on SCM? That'd perhaps be better left for additional macros?
    Last edited by Juggalo20; 10-08-11 at 06:51 AM.
    10-08-11 06:14 AM
  19. Vijik's Avatar
    I notice feature reqs seem to end up in the macro thread more often than not. But I'm guessing this might be a better spot. Correct me if I'm wrong. Annnyways, I was kinda thinking, of an comment setup. Like
    /* comment */, or even just a prefex to ignore an single command. Like -Ding100 wouldn't actually Ding. I like to think I'm up to speed on what's available in SCM, but I did join the party late so if I missed this somewhere in the like 700 posts in the macro thread and the couple other SCM threads ... Sorry

    Posted from my CrackBerry at wapforums.crackberry.com

    Edit #1
    Or would that put too much strain on SCM? That'd perhaps be better left for additional macros?
    This is good thread to request new features and report bugs.

    /* Commented out */ is already implemented.

    You can comment out any part of the macros by putting them between '/*' '*/'.

    I can add '-' as a disabler. It is actually very easy. But I think /* */ should cover that.
    Last edited by Vijik; 10-08-11 at 11:04 AM.
    10-08-11 10:58 AM
  20. TomCanuck's Avatar
    This is good thread to request new features and report bugs.

    /* Commented out */ is already implemented.

    You can comment out any part of the macros by putting them between '/*' '*/'.

    I can add '-' as a disabler. It is actually very easy. But I think /* */ should cover that.
    Oh deadly so many many SCM posts lol was only a matter of time till I missed something lol. Awesome ^_^

    Posted from my CrackBerry at wapforums.crackberry.com
    10-08-11 11:11 AM
  21. TomCanuck's Avatar
    5.9.0.2 seems to have fixed most things up nicely ^_^ running on 9900/7.0.0.440

    KeypadLockKey works as expected, setting $var from $$Result or $$Rest works and MediaKeyBooster's StopMacro breaks out of a suspended maco

    Sum 1,2;
    Set $test1=$$Result;
    Sub 20,1;
    Set $test2=$$Result;
    Div 20, 3;
    Set $test3=$$Result;
    Set $test4=$$Rest;
    Div 20,5;
    Set $test5=$$Result;
    set $test6=$$Rest;
    Show $test1 $test2 $test3 $test4 $test5 $test6;

    I did find a way to break something... I think... Let me know if this is user error or ...
    WARNING this WIILL hit keys in a location you will NOT be expecting it to. In order to test this SAFELY please follow the steps!

    ShortcutMe macro:
    App Name: MemoPad_New
    Macros:
    NavMoveDown1;
    KeyFirst part;EnterKey;
    Vibrate500;
    Suspend;
    KeySecond part;EnterKey;
    Suspend;
    KeyThird Part;EnterKey;
    Suspend;
    EscKey;NavMoveDown1;NavClick

    At NO time should you mess with the order of your windows, MemoPad should at all times remain the App Directly behind SCM.
    Step #1. Open MemoPad
    Step #2. Open a new memo
    Step #3. Launch the ShortcutMe macro written above
    Step #4. Wait for the Vibrate and "First Part" is typed, EnterKey is hit
    Step #5. Hit your convience key to launch ShortcutMe_Touch to continue after the Suspend;. Now, my assumption was "Second Part" would be typed, however, it isn't. Nothing happenes.
    /* here's what confused me and why I included such detailed steps and a warning */
    Press the EscKey, Discard Changes.
    BAM! "Second Part" gets typed into the original New Memo we created manually
    The rest of the macro executes as expected in the manually created memo.

    Posted from my CrackBerry at wapforums.crackberry.com
    10-08-11 08:39 PM
  22. gbsn's Avatar
    5.9.0.2 seems to have fixed most things up nicely ^_^ running on 9900/7.0.0.440

    KeypadLockKey works as expected, setting $var from $$Result or $$Rest works and MediaKeyBooster's StopMacro breaks out of a suspended maco

    Sum 1,2;
    Set $test1=$$Result;
    Sub 20,1;
    Set $test2=$$Result;
    Div 20, 3;
    Set $test3=$$Result;
    Set $test4=$$Rest;
    Div 20,5;
    Set $test5=$$Result;
    set $test6=$$Rest;
    Show $test1 $test2 $test3 $test4 $test5 $test6;

    I did find a way to break something... I think... Let me know if this is user error or ...
    WARNING this WIILL hit keys in a location you will NOT be expecting it to. In order to test this SAFELY please follow the steps!

    ShortcutMe macro:
    App Name: MemoPad_New
    Macros:
    NavMoveDown1;
    KeyFirst part;EnterKey;
    Vibrate500;
    Suspend;
    KeySecond part;EnterKey;
    Suspend;
    KeyThird Part;EnterKey;
    Suspend;
    EscKey;NavMoveDown1;NavClick

    At NO time should you mess with the order of your windows, MemoPad should at all times remain the App Directly behind SCM.
    Step #1. Open MemoPad
    Step #2. Open a new memo
    Step #3. Launch the ShortcutMe macro written above
    Step #4. Wait for the Vibrate and "First Part" is typed, EnterKey is hit
    Step #5. Hit your convience key to launch ShortcutMe_Touch to continue after the Suspend;. Now, my assumption was "Second Part" would be typed, however, it isn't. Nothing happenes.
    /* here's what confused me and why I included such detailed steps and a warning */
    Press the EscKey, Discard Changes.
    BAM! "Second Part" gets typed into the original New Memo we created manually
    The rest of the macro executes as expected in the manually created memo.

    Posted from my CrackBerry at wapforums.crackberry.com
    Memopad_new doesn't launch the memopad app, it is shortcutme using the bb os API to create a new memo directly. If you look at the app switcher, you will see SCM is the one running not memopad, and macros will behave strange because they are running over SCM and not memopad. Its been noted before with one of the compose functions of SCM if i remember well and its just how the API does it.

    Just do it manually, launch memopad;navmoveup1;enterkey; (if a memo is not already open)
    Last edited by gbsn; 10-09-11 at 11:17 AM.
    10-09-11 11:15 AM
  23. TomCanuck's Avatar
    Memopad_new doesn't launch the memopad app, it is shortcutme using the bb os API to create a new memo directly. If you look at the app switcher, you will see SCM is the one running not memopad, and macros will behave strange because they are running over SCM and not memopad. Its been noted before with one of the compose functions of SCM if i remember well and its just how the API does it.

    Just do it manually, launch memopad;navmoveup1;enterkey; (if a memo is not already open)
    Ahha. Okie dokie

    Posted from my CrackBerry at wapforums.crackberry.com
    10-09-11 11:41 AM
  24. Vijik's Avatar
    ShortcutMe is now updated to 5.9.1.0 for following BB models running BB OS 7.0:
    9900, 9930, 9810, 9850, 9860, 9350, 9360, and 9370

    It is also updated to 5.6.1.0 for following models running BB OS 4.3+ to 6.x:
    9800, 97xx, 96xx, 95xx, 93xx, 91xx, 90xx, 89xx, 88xx, 85xx, 83xx, 82xx, and 81xx


    New in this update:

    - Following macros are added
    'Show' (Shows a message, and gives option to continue or stop macros afterwards)

    'IsHeadSetConnected' (Returns TRUE if a headset is connected to the BB)

    'KeypadLockKey' (Locks the keypad)

    - If * is added in front of the key clicking macros, those macros will turn them into SpecialKey Click macros

    - Removed 'SetVolume' macro

    - Removed the bug related to 'Set' macro

    - Remote apps can now stop suspended macros.
    TomCanuck and anon(4113192) like this.
    10-09-11 11:46 AM
  25. gbsn's Avatar
    How complex would it be to create an elseif ("elseif0 blabla;elseif0 blabla") statement? Currently, you have to manually nest a bit if you want to create several "linear?" conditionals that depend on the previous one or you only need 1 execution out of several conditions, because two different consecutive if statements wont work the same way as they both will be executed. Specially now that we can have multiple conditions in an if statement and an else will not satisfy specific else conditions but all the other else conditions.
    If statements that check a variable for several values would also be shortened a lot and look cleaner.
    Last edited by gbsn; 10-09-11 at 09:55 PM.
    10-09-11 09:38 PM
712 ... 34567 ...
LINK TO POST COPIED TO CLIPBOARD