Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

Need help developing a menu navigation system

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

    Need help developing a menu navigation system

    I am new to Alpha and could use some assistance developing a basic application / menu navigation system. I have an old concept I developed in FileMaker Pro and would like to port it to Alpha. I would appreciate any assistance on the best method of accomplishing this via Alpha5 V10.

    See the attached PDF for a rough visual of the description in this post. I am completely open to ideas so please provide any and all feedback. I would like the navigation system to be clean, easy to update and would gladly share it with the forum once developed.

    The concept consists of two sections; we can call the sections, menu navigation (Left) and Section layout display (right).

    The menu navigation consists of a drop down showing the available modules (Rolodex, Engineering, Sales, Etc.) and when a module is selected the sections (buttons) for that module show. The Section layout (right side) simple shows the form for the selected section (Button).

    In the FileMaker DB I did this by showing and hiding the various menu navigation forms (Left). Each module had its own form and when the module was selected via the drop-down that particular module form was shown and the other forms were hidden. This avoided scripting and adding a section was as easy as adding a button to a form.

    Reference the PDF and the description below as an example.

    In Figure 1 you can see the drop down showing the available modules (Rolodex, Engineering, Sales).

    In figure 2 Rolodex was the selected module. Customers, Employees and Vendors are the available sections (buttons).

    In figure 2 Customers was selected and therefore the Customer form displays on the right.

    Figures 3 & 4 illustrate different examples based on the same concept.

    Figure 3 - Shows the Specs form displaying after selecting "Engineering" from the drop down and clicking the "Specs" button.

    Figure 4 - Shows the Call Log form displaying after selecting "Sales" from the drop down and clicking the "Call Log" button.

    #2
    Re: Need help developing a menu navigation system

    There's a few ways to do this. Here's a simple example I put together. (I did not spend any time on the sub-menu buttons so they do not function).

    I hope this can get you started.

    Comment


      #3
      Re: Need help developing a menu navigation system

      Scott,

      Alpha gives you two ways in which to create a hierarchical
      tree from which forms can be launched:

      1. Alpha tree control (no limit on number of nodes/leaves)
      2. Alpha supercontrol (limit of two levels only)

      One possible problem with your approach is that you appear to want the menu to always be visible at the left of the screen. I assume you are willing to do a lot of redundant coding.

      Unlike Microsoft Access, Alpha will not allow to place unrelated table information on a form, for example, from a table for your menu items and a table for your contact information. You can create a "fake" set to make this work.

      You can of course hard code your menu structure, but this approach quickly presents problems as your application grows or changes.

      Most "real-world" applications like your drawing allow the user to widen or expand the menu area, and conversely narrow the contact information. This is often accomplished with what in Visual Studio is known as a splitter bar. Unfortunately, there is no splitter bar on the market that I am aware of that works with Alpha Five. So you're out of luck.

      But all is not lost. Because Alpha displays open forms on tabs at the bottom of the screen, you can call your frmMenu just Menu, which will appear on the tab. Thus users can quickly return to the menu by clicking on the tab at the bottom of the screen.

      But alas another problem surfaces. Alpha opens new tabs to the left of the current tab, not to the right. You probably would want the tab for your menu form always to remain in the far left position, just so users can instinctively return to it. I haven't found away around this problem.

      Here's a link to something I put in the code library which may give you some ideas:

      http://msgboard.alphasoftware.com/al...c+menu+activex

      Bottom line: An application menu is best presented on a separate form and the left screen area in your drawings is best used for nagivation within a selected form.

      Bob McGaffic
      Pittsburgh, PA

      Comment


        #4
        Re: Need help developing a menu navigation system

        Originally posted by RCarvalho View Post
        There's a few ways to do this. Here's a simple example I put together. (I did not spend any time on the sub-menu buttons so they do not function).

        I hope this can get you started.
        I appreciate you putting your example together. Unfortunately I am still new enough to Alpha that "how" you are doing this is not poping out at me. How are you manipulating which menu items show/hide? How are you doing the button replacement under the main menu? I can find all the flyover type effects but not scripting or actions that are showing/hiding the form buttons. Can you provide a quick explanation?

        I think this will suite my needs as long as it is easy to modify. I am hoping to develop a solution that does not have a lot of redundant code/forms creation to add a new section. Since Alpha does not allow info from two different tables on one form I would like to have two forms one on the left and one on the right. The left one would be linked to a "MenuNav" table and would contain the menu item info. The menu navigation would control the form to display on the right via showing or hiding them. What would be the best way to accomplish this?

        Comment


          #5
          Re: Need help developing a menu navigation system

          Originally posted by rmcgaffic View Post
          Scott,

          Alpha gives you two ways in which to create a hierarchical
          tree from which forms can be launched:

          1. Alpha tree control (no limit on number of nodes/leaves)
          2. Alpha supercontrol (limit of two levels only)

          One possible problem with your approach is that you appear to want the menu to always be visible at the left of the screen. I assume you are willing to do a lot of redundant coding.

          Unlike Microsoft Access, Alpha will not allow to place unrelated table information on a form, for example, from a table for your menu items and a table for your contact information. You can create a "fake" set to make this work.

          You can of course hard code your menu structure, but this approach quickly presents problems as your application grows or changes.

          Most "real-world" applications like your drawing allow the user to widen or expand the menu area, and conversely narrow the contact information. This is often accomplished with what in Visual Studio is known as a splitter bar. Unfortunately, there is no splitter bar on the market that I am aware of that works with Alpha Five. So you're out of luck.

          But all is not lost. Because Alpha displays open forms on tabs at the bottom of the screen, you can call your frmMenu just Menu, which will appear on the tab. Thus users can quickly return to the menu by clicking on the tab at the bottom of the screen.

          But alas another problem surfaces. Alpha opens new tabs to the left of the current tab, not to the right. You probably would want the tab for your menu form always to remain in the far left position, just so users can instinctively return to it. I haven't found away around this problem.

          Here's a link to something I put in the code library which may give you some ideas:

          http://msgboard.alphasoftware.com/al...c+menu+activex

          Bottom line: An application menu is best presented on a separate form and the left screen area in your drawings is best used for nagivation within a selected form.

          Bob McGaffic
          Pittsburgh, PA
          Bob, Thank-you for the reply. Unfortunately I cannot find the Component Toolbox product mentioned in the instructions at the www.dbi-tech.com website. Can you provide a link?

          I have not investigated the alpha tree control yet but I am curious is there a reason why you would not use the integrated tree control?

          Comment


            #6
            Re: Need help developing a menu navigation system

            Scott

            This may or may not be what you are looking for. I posted this in the code archive awhile back. I use the xdialog supercontrol with Alpha's built in tree control. In my example you can have different icons for open or closed nodes. The menu is dynamically generated for each user's permissions from the menu table and is based on who logged in.

            I have since tweaked this a little bit for my needs.....but the core is there for you if something like this will fit your needs.

            Regards,

            Jeff

            Comment


              #7
              Re: Need help developing a menu navigation system

              Originally posted by jkletrovets View Post
              Scott

              This may or may not be what you are looking for. I posted this in the code archive awhile back. I use the xdialog supercontrol with Alpha's built in tree control. In my example you can have different icons for open or closed nodes. The menu is dynamically generated for each user's permissions from the menu table and is based on who logged in.

              I have since tweaked this a little bit for my needs.....but the core is there for you if something like this will fit your needs.

              Regards,

              Jeff
              Jeff, Thank-you for your example. Greaat Job! This is very close to what I am looking for and do have a couple of questions for you.

              1. How would I make it so the menu help control only one form being open at a time? Meaning if I browse in the menu and open form 1 and then browse on the menu and open form 2 how do I get it to close the current open form (but not the menu form?) Basically I would like the "menu navigation" to control what shows on the right side, where I want to display the various forms.

              2. When I originally open the "app" I want to make it so there is a splash screen/form displaying on the right. I know this really does not have to do with the Menu but was hoping you could help. Would it be easiest to just have an autoexec script that shows both the menu navigation and the splash screen forms?

              3. The field Ctrlpnltypf, how is this used? I understand it defines the type of menu item but is this repquired when showing a form over a report? Or is this just information for the admin?

              Comment


                #8
                Re: Need help developing a menu navigation system

                Scott,

                You have noted exactly the design issues I earlier struggled with.

                The problem I see is this:

                You have four tables:
                Menu items
                Customer
                Materials
                Employees

                Do you wish to have three standalone forms for Customer, Materials, and Employees, with the Menu items displayed at the left of each of those three forms? You would have to repeat your code for the menu tree control on each form. Cut and paste of this magnitude does not make for easy future maintenance.

                If so, to display both MenuItems and Customers on the form it is necessary to create a "fake" set: let's call it MenuCustomers.
                You would have to similary create a "fake" set for MenuMaterials and MenuEmployees.

                On the other hand, you might want to create only one form, which includes a tree at the left of the form and a subform on the right. This is very easy to do in MS Access, but I have not done it with Alpha Five. Basically, when you click make a menu selection, the subform is switched out-- say from customer to employee.

                If so, you will need a set that combines all four tables: Menu items, Customers, Materials, and Employees. Others on this forum have commented that creating large sets is not a good design approach. Essentially you would have a set that included every table in your application.

                As you can see neither of these approaches scales up well. They might work for a very small application, but nothing serious.

                All of this is why I suggested the approach on my original posting: Combine main menu and splash/welcome on one form, and create separate forms with no main menu on separate forms for Customer, Materials, and Employees.

                Did I tell you I earlier thought about using a dockable panel? If you are new to Alpha you probably appreciate the visual design and flexibility that desktops give you. Dockable forms
                can not, to my understanding, by imposed on top of desktop forms.
                To use them you must be ready for some very serious coding using XDialog not only of the dockable panel, but ALSO the form on which it resides.

                I would love to be proved wrong by someone who has done this:
                Place menu inside a dockable panel (OK, to use XDialog for just this feature) and then place the dockable panel on the far left of your desktop form, much like the toolbox in design mode.

                Bob McGaffic
                Pittsburgh

                Comment


                  #9
                  Re: Need help developing a menu navigation system

                  Originally posted by rmcgaffic View Post
                  Scott,

                  You have noted exactly the design issues I earlier struggled with.

                  The problem I see is this:

                  You have four tables:
                  Menu items
                  Customer
                  Materials
                  Employees

                  Do you wish to have three standalone forms for Customer, Materials, and Employees, with the Menu items displayed at the left of each of those three forms? You would have to repeat your code for the menu tree control on each form. Cut and paste of this magnitude does not make for easy future maintenance.

                  If so, to display both MenuItems and Customers on the form it is necessary to create a "fake" set: let's call it MenuCustomers.
                  You would have to similary create a "fake" set for MenuMaterials and MenuEmployees.

                  On the other hand, you might want to create only one form, which includes a tree at the left of the form and a subform on the right. This is very easy to do in MS Access, but I have not done it with Alpha Five. Basically, when you click make a menu selection, the subform is switched out-- say from customer to employee.

                  If so, you will need a set that combines all four tables: Menu items, Customers, Materials, and Employees. Others on this forum have commented that creating large sets is not a good design approach. Essentially you would have a set that included every table in your application.

                  As you can see neither of these approaches scales up well. They might work for a very small application, but nothing serious.

                  All of this is why I suggested the approach on my original posting: Combine main menu and splash/welcome on one form, and create separate forms with no main menu on separate forms for Customer, Materials, and Employees.

                  Did I tell you I earlier thought about using a dockable panel? If you are new to Alpha you probably appreciate the visual design and flexibility that desktops give you. Dockable forms
                  can not, to my understanding, by imposed on top of desktop forms.
                  To use them you must be ready for some very serious coding using XDialog not only of the dockable panel, but ALSO the form on which it resides.

                  I would love to be proved wrong by someone who has done this:
                  Place menu inside a dockable panel (OK, to use XDialog for just this feature) and then place the dockable panel on the far left of your desktop form, much like the toolbox in design mode.

                  Bob McGaffic
                  Pittsburgh
                  Bob, Take a look at the post/example from Jeff Kletrovets, He uses XDialog to build a dynamic menu based on the authenticated user.

                  Comment


                    #10
                    Re: Need help developing a menu navigation system

                    Jeff, Thank-you for your example. Greaat Job! This is very close to what I am looking for and do have a couple of questions for you.

                    1. How would I make it so the menu help control only one form being open at a time? Meaning if I browse in the menu and open form 1 and then browse on the menu and open form 2 how do I get it to close the current open form (but not the menu form?) Basically I would like the "menu navigation" to control what shows on the right side, where I want to display the various forms.

                    2. When I originally open the "app" I want to make it so there is a splash screen/form displaying on the right. I know this really does not have to do with the Menu but was hoping you could help. Would it be easiest to just have an autoexec script that shows both the menu navigation and the splash screen forms?

                    3. The field Ctrlpnltypf, how is this used? I understand it defines the type of menu item but is this repquired when showing a form over a report? Or is this just information for the admin?
                    Scott,

                    I'll go down your item list.

                    Item 1 from above - I will make an example and post it here for you tonight that does this. Too busy today.

                    Item 2 - This is no problem. I'll incorporate this into my example.

                    Item 3 - This is one area that I have tweaked (that I referenced in my original post). I do not use the Ctrlpnltypf field any more. I now use buttons that I hide and I just "push" the appropriate button that is hidden on the main menu form original. I found this to be easier because then I could use custom code on each button depending on what I was doing. This will be in the example as well.


                    Regards,

                    Jeff

                    Comment


                      #11
                      Re: Need help developing a menu navigation system

                      Just a couple of follow-up comments:

                      Rui Carvalho has a good looking menu system, which unfortunately is limited to two levels deep for a tree.

                      Here's what Alpha' supercontrol looks like fully expanded:
                      Customers
                      --Add customer
                      --Change customer
                      --Delete customer
                      --Print customer report
                      Vendors
                      --Add a vendor
                      --Change vendor, etc.
                      Employees
                      --Add an employee
                      --Change an employee, etc.

                      Rui's example is different in that not all nodes are displayed at the same time, thus:

                      Customers
                      Vendors
                      Employees
                      Add a vendor
                      Change a vendor, etc.

                      Again this approach is fine for a very small application. It does not scale at all. In fact, the approach is best used not for menuing systems, but as a form navigation system applicable to the current form only.

                      Jeff's example is very similar to my code library example.

                      In my example, I launch the standalone form on the double click event while Jeff does the same thing using a button placed on the form.

                      Neither of these what Scott originally requested.

                      Jeff's a creative guy and I'm looking forward to his example on how on a single form to display a tree menu and a selected form with the following challenges:

                      1. No cumbersome set definition
                      2. No repetitive hard coding
                      3. Use at least four tables Menu, Customers, Vendors, Employees
                      4. XBasic code only

                      My hat's off to anyone who can do this following using a Docking Panel with desktop forms!

                      Bob McGaffic
                      Pittsburgh, PA

                      Comment


                        #12
                        Re: Need help developing a menu navigation system

                        Attached please find the example I worked up for Scott as well as the attached screenshots.

                        Some items of note.

                        1. Try logging in as the 2 different people below and notice the menu choice difference for Scott - he will be missing one of the Rolodex menu items as it is not checked for him in the dynamic menu table.

                        Username: Jeff
                        Password: Jeff

                        Username: Scott
                        Password: Scott

                        2. I have changed the approach on this as to what code to run after the user makes a selection. In my original example, I would simply push a hidden button named in the master menu template table (and then by default in the dynamic menu table since those items are copied from the master using the supplied button)....now the btnnamef field(button name field) in the menu tables contains the name of a UDF to run when that menu item is selected.

                        3. I have created the UDF's for all menu items in this example. Only the rolodex menu items will open a form as those are the only ones I created. The other menu choices will show you what form would have ran if it existed.

                        4. To create a new UDF for a new menu item(if you want to add more menu items than I created in this example)....just right click on any of the existing menu item UDF's in the control panel and choose "Duplicate". Give the UDF a new name - that you will use in the master menu table for the new entry.

                        5. ***Important** There is a "Starter Form" (StarterForm_frm) in the forms tab in the control panel. If you want to create a new form for a another menu item - just right click on this form and choose "Copy To...". Give this new form a new name and choose the table / set that you want it to be copied to. This gives you the basic menu template on a "Blank form" that is "connected" to your new table.

                        6. You would want to remove or hide or make invisible the show control panel button in your live app. I often make it invisible and pretty dang small...so if I want into the CP...I just click the upper right (or wherever) corner to push the button.


                        You will notice if you click on the "Customer Rolodex" entry..... that form will open and any other form you have open will close (except for the main menu). Now click on the "Vendor Rolodex" entry and the customer rolodex form will close and you will be viewing the vendor rolodex form.


                        Obviously, this needs polished and beautified and made to conform to whatever aesthetics you find desirable but hopefully this will get you where you want to go.

                        Regards,

                        Jeff

                        Comment


                          #13
                          Re: Need help developing a menu navigation system

                          Here is a revised demo. Exact same functionality - but this is better going forward because I have made the menu code external to the supercontrol (a script in the Control Panel). This way if a change is needed in the menu code.....it can just be made in this one script and it will be "seen" by all forms instantly.

                          Regards,

                          Jeff

                          Comment


                            #14
                            Re: Need help developing a menu navigation system

                            Jeff,

                            Would it possible to post your most recent demo with the control panel accessible. When I click on either of your demo applications, they launch directly and I can't see the forms, tables, and functions that you've used.

                            I suspect this would also be helpful to other new users.

                            Thanks,
                            Bob McGaffic
                            Pittsburgh, PA

                            Comment


                              #15
                              Re: Need help developing a menu navigation system

                              Sure Bob,

                              Here it is. There have been numerous improvements on this from the other day. I have worked with Scott offline on a few things and those are incorporated here. I thought I put a "Show Control Panel" button on the original sample...but maybe not. In any case, here it is with the ability to see the Control Panel.

                              Items of note on this verison.

                              1. The code was greatly streamlined for the generation of the crlf list for the menu tree. I had "stolen" this code from my normal menu system I use that has the tree code defined right with the xdialog supercontrol. The problem with this method where there is a tree on every form - the crlf list was getting regenerated every time a new form was chosen from the menu.....a big waste. So, I pulled that out so the crlf list for the menu is created right after the user logs in and is just passed to the tree now. Much more efficient.

                              2. The tree will now open to the selected choice when you move from form to form instead of being collapsed (which is the default).

                              3. I changed the sequencing for closing the "old form" that needs to be closed when a new one is chosen since Scott wants only to have 2 forms open at time. BTW, for anyone who does not want the 2 form limit.....just comment out the MenuChoice_CloseForms UDF in each of the UDF's that get run with each menu item. I was closing the old form first and then opening the new form in the previous verison which caused some "flicker" as you briefly saw the Main Menu when the new form was opening. This new method is smoother.


                              I think that is about it.

                              Regards,

                              Jeff

                              Comment

                              Working...
                              X