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

UX Cascading Dropdown

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

    UX Cascading Dropdown

    I hope someone can help...

    This one should be very easy, but I've been plugging away for more than an hour and I can't get it.

    In short, I've created a UX with 2 dropdown fields: ST_NO (for Store #) and TrainingDate

    The ST_NO field is populated from a SQL Server Table called "StoreInfo" (which lists every Store # and some other fields with information about the stores). In that table, ST_NO is "unique" (there is only 1 of each Store #... obviously). That's the "Parent" field

    Then, I have a table called "TrainingDates" which lists all classes that have ever been scheduled. That table has a field for "ST_NO" and a field for "TrainingDate" (the date of the class). There are other fields in the table, but not used for this lookup.

    Here's what I want to do: I want the user to select a "Store #" and have the TrainingDate lookup display all of the Training Dates that were scheduled for that Store.

    Sounds easy enough... BUT, no matter how I configure it, after selecting the Store #, the UX "locks up" (I get Microsoft's "waiting" circle and I can't do anything unless I forcefully close Alpha Anywhere, completely and then restart it). ST_NO is a Numeric Field (in both tables and on the UX) and Training Date is a "Date" field. I thought this would be easy, but I've tried so many variations and none worked (In fact, my ultimate goal is to further filter the "TrainingDate" field to display only Training Dates that occurred during the past two weeks (without the cascading, I can get that filter to work without any problem: WHERE TrainingDate BETWEEN (Now()-15) AND Now())).

    So, I can use some help from someone who can figure out why this isn't working. The images below show what I've done so far:

    This is what the dropdowns look like on the form, itself:
    Alpha1.jpg

    This is how I've programmed the "Store #" (ST_NO) field:
    Alpha2.jpg

    Finally, this is how I programmed the "TrainingDate" cascading field:
    Alpha3.jpg

    As I said, I've tried so many variations ("explicit", choosing both fields from the same Table (TrainingDates, using DISTINCT, and many more). The problem is always the same: As soon as I choose the Store #, the whole program locks up.

    If you can help, "I'll be your best friend".

    Thanks,
    Phil

    #2
    Re: UX Cascading Dropdown

    https://www.screencast.com/t/dcbOyIlAV
    change from auto to explicit.
    then fill in the filter
    adjust to the way you have the table and the store number.
    like
    st_no = :N_store_info
    to make it easier type in the field st_no = then ask alpha to add the argument and type

    https://www.screencast.com/t/76hBDQiatIlg

    https://www.screencast.com/t/MsxnVIOzi

    https://www.screencast.com/t/bjB5DjymPIfs
    Last edited by GGandhi; 01-25-2017, 03:15 AM.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    [email protected]
    Skype:[email protected]
    1 914 924 5171

    Comment


      #3
      Re: UX Cascading Dropdown

      Hi Ghandi-

      Thank you so much for writing.

      Unfortunately, I had already tried that, but the system still locked up.

      I just just tried it again (see below) and, of course, it locked up again... so, I'm still stuck.
      Alpha4.jpg

      Phil

      Comment


        #4
        Re: UX Cascading Dropdown

        i think you typed the information
        if alpha did it then it would have been
        ST_NO = :N_storeInfo
        ask alpha to insert the argument.
        thanks for reading

        gandhi

        version 11 3381 - 4096
        mysql backend
        http://www.alphawebprogramming.blogspot.com
        [email protected]
        Skype:[email protected]
        1 914 924 5171

        Comment


          #5
          Re: UX Cascading Dropdown

          Alpha DID type in the information... I did exactly what you suggested: I typed "ST_NO =" and let Alpha do the rest. It selected the field and also select the "N" (Numeric) characteristic. I wish the solution were that easy.

          Comment


            #6
            Re: UX Cascading Dropdown

            then your cascading itself needs to be examined:
            i am showing what i did, is this what you did?
            https://www.screencast.com/t/zgFw72mu
            thanks for reading

            gandhi

            version 11 3381 - 4096
            mysql backend
            http://www.alphawebprogramming.blogspot.com
            [email protected]
            Skype:[email protected]
            1 914 924 5171

            Comment


              #7
              Re: UX Cascading Dropdown

              Yes, my code is EXACTLY like yours, but it's still not working. Been a long night, so I'm going to take a break (get some sleep). Try again later in the morning.

              Comment


                #8
                Re: UX Cascading Dropdown

                i was wrong when i said if alpha did it would have been :N_storeInfo, no it would have been as you had.
                but try a little different way.
                for trainingdates do not add the st_id for lookup. just select trainingdate from trainingdates ( leave out the st_no)
                thanks for reading

                gandhi

                version 11 3381 - 4096
                mysql backend
                http://www.alphawebprogramming.blogspot.com
                [email protected]
                Skype:[email protected]
                1 914 924 5171

                Comment


                  #9
                  Re: UX Cascading Dropdown

                  okay i did with date filtering using between clause, but i did all thru alpha ( your now()-15 AND now() does not seem right to me)
                  so here is the result
                  https://www.screencast.com/t/wv0qgqAB
                  and my select date for training dates look like this:
                  Code:
                  SELECT DISTINCT training_date  FROM training_dates  WHERE training_date BETWEEN  AddDaysToDate( CurrentDate() ,  -10)  AND  CurrentDate()   ORDER BY training_date
                  thanks for reading

                  gandhi

                  version 11 3381 - 4096
                  mysql backend
                  http://www.alphawebprogramming.blogspot.com
                  [email protected]
                  Skype:[email protected]
                  1 914 924 5171

                  Comment


                    #10
                    Re: UX Cascading Dropdown

                    Phil,

                    What Alpha Build are you using? I've tried this with build 4109, 4089, and 3962 and I'm not seeing the issue you are.

                    Your TrainingDate dropdown SELECT statement is a bit odd. You have "SELECT DISTINCT TrainingDate, ST_NO...". Why ST_NO? This would Store the value of the ST_NO in the TrainingDate field... and not the TrainingDate selected. Even so... it works and no error occurs.

                    Everything else looks ok.

                    Attached is my UX... you'll need to change the Connection string in the dropdowns.

                    My Table names are StoreInfo and TrainingDates. StoreInfo has ST_NO and ST_NAME. TrainingDates has TR_NO, ST_NO, and TrainingDate. Everything else is set to <Auto>

                    My Select statement for TrainingDates is...

                    Code:
                    SELECT DISTINCT TrainingDate FROM TrainingDates  WHERE TrainingDate BETWEEN ( Now()  - 15) AND  Now() ORDER BY TrainingDate
                    Post a sample UX and I'll have a look.

                    ux_Cascading_Dropdowns_SQLServer16.a5wcmp

                    Comment


                      #11
                      Re: UX Cascading Dropdown

                      Hi David and Ghandi-

                      Thanks so much for continuing to work with me on this issue. Here's the Update: In short, everything's working EXACTLY the way I wanted it to work and I really appreciate all your help. Interestingly, last night, I tried all the things you had suggested, but I could never get it to work. So, today, after reading your comments, I simply deleted the controls and just recreated them from scratch. I can't tell you why, but, today, it worked perfectly. I don't think I did anything differently... and, last night, I tried so many variations, but couldn't get it work.

                      Anyway, deleting the controls and rebuilding them worked. In case anyone else is reading this thread, I've posted a couple of images, of the final code/formulas I used:
                      Alpha7.jpg Alpha5.jpg Alpha6.jpg

                      Once again, thanks for all your help. Now, on to the next challenge.

                      Phil

                      Comment

                      Working...
                      X