Announcement

Collapse
No announcement yet.

Running App with parameters from the MENU

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Running App with parameters from the MENU

    I need to use this MACRO to open a FORM from the MENU in "Insert New Record" mode.

    sc_apl_conf("my_form", "start", "new");

    There are no really any embed points (events) to be able to control when the menu selection is made. How can I call this form from the menu ?

    Art
    -----------------------------------------
    Arthur Klisiewicz
    dATA POINT SOFTWARE
    www.datapointsoftware.com

  • #2
    Hi Arthur,
    You can add below code in 'OnExecute' event in menu application. Item number can be found under properties of each menu item. If the item no is 38 then code will look like below;

    if ({sc_menu_item} == "item_38")
    {
    sc_apl_conf("my_form", "start", "new");
    }

    Hope this helps.
    Cheers,
    Aari

    Comment


    • #3
      Originally posted by aka View Post
      I need to use this MACRO to open a FORM from the MENU in "Insert New Record" mode.

      sc_apl_conf("my_form", "start", "new"

      There are no really any embed points (events) to be able to control when the menu selection is made. How can I call this form from the menu ?

      Art
      Yes it is. Saari told you how.
      /Giuseppe

      Professional Scriptcase Services
      Some Customers opinions

      Comment


      • #4
        OK, I thought "OnExecute" event applies to the whole Menu (not the menu item). they should change the event name to something like " OnExecItem" - it would be much more descriptive.

        Thanks - ARTHUR
        -----------------------------------------
        Arthur Klisiewicz
        dATA POINT SOFTWARE
        www.datapointsoftware.com

        Comment


        • #5
          The menu item reads number 15. I placed this code but when I click the menu selection nothing happens. what am I missing ?


          PHP Code:
          if ({sc_menu_item} == "item_15")
          {
          sc_apl_conf("form_t_newtc_4co""insert""on");

          Last edited by aka; 12-10-2015, 09:54 PM.
          -----------------------------------------
          Arthur Klisiewicz
          dATA POINT SOFTWARE
          www.datapointsoftware.com

          Comment


          • #6
            If you are inserting a new record then how about using "start", "new" parameters instead of "insert", "on"

            Comment


            • #7
              I tried that as well. Clicking on the menu item simply has no results at all
              -----------------------------------------
              Arthur Klisiewicz
              dATA POINT SOFTWARE
              www.datapointsoftware.com

              Comment


              • #8
                Hmm I am not sure. It is working for me and my version is 8.1. Could it be a security issue? Is the user has access to 'Insert'? But if it is that you will receive an 'Unauthorised User' message.

                Comment


                • #9
                  at this moment the whole Security is disabled
                  -----------------------------------------
                  Arthur Klisiewicz
                  dATA POINT SOFTWARE
                  www.datapointsoftware.com

                  Comment


                  • #10
                    OK, I'm stuck here. Could somebody please confirm if this macro is working and if there are any extra steps necessary to make it work (except inserting the code above) into "OnExecute" event ?
                    -----------------------------------------
                    Arthur Klisiewicz
                    dATA POINT SOFTWARE
                    www.datapointsoftware.com

                    Comment


                    • #11
                      Originally posted by aari77 View Post
                      if ({sc_menu_item} == "item_38")
                      {
                      sc_apl_conf("my_form", "start", "new");
                      }
                      Aari, Thanks! This is just what I needed. Worked great, well after I fixed a typo in my form name.
                      Thanks again,
                      Bill

                      ada, the code worked as is for me. All I did was use the correct item_# and my form name. I hope you find the issue.
                      Last edited by bwalk; 01-06-2016, 12:43 AM.

                      Comment

                      Working...
                      X