Alpha Video Training
Results 1 to 11 of 11

Thread: UX Cascading Dropdown

  1. #1
    Member
    Real Name
    Phil Samuels
    Join Date
    Jan 2011
    Posts
    195

    Default 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. #2
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,294

    Default 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 at 03:15 AM.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  3. #3
    Member
    Real Name
    Phil Samuels
    Join Date
    Jan 2011
    Posts
    195

    Default 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

  4. #4
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,294

    Default 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
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  5. #5
    Member
    Real Name
    Phil Samuels
    Join Date
    Jan 2011
    Posts
    195

    Default 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.

  6. #6
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,294

    Default 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
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  7. #7
    Member
    Real Name
    Phil Samuels
    Join Date
    Jan 2011
    Posts
    195

    Default 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.

  8. #8
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,294

    Default 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
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  9. #9
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,294

    Default 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
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  10. #10
    "Certified" Alphaholic
    Real Name
    David Kates
    Join Date
    Apr 2008
    Location
    Unionville, ON
    Posts
    7,814

    Default 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

  11. #11
    Member
    Real Name
    Phil Samuels
    Join Date
    Jan 2011
    Posts
    195

    Default 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

Similar Threads

  1. Cascading Dropdown Help
    By SevinD0991 in forum Application Server Version 11 - Web/Browser Applications
    Replies: 0
    Last Post: 01-06-2014, 11:51 AM
  2. Dropdown cascading problem
    By haimbeyhan in forum Mobile & Browser Applications
    Replies: 7
    Last Post: 05-09-2013, 10:50 AM
  3. Cascading Dropdown in Dialog: Second Dropdown is blank
    By josevelez in forum Application Server Version 11 - Web/Browser Applications
    Replies: 2
    Last Post: 01-12-2012, 05:55 PM
  4. Cascading Dropdown
    By jacktheripper in forum Application Server Version 10 - Web/Browser Applications
    Replies: 3
    Last Post: 01-08-2011, 01:37 PM
  5. Cascading Dropdown
    By Jberry in forum Application Server Version 10 - Web/Browser Applications
    Replies: 1
    Last Post: 02-21-2010, 10:06 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •