Announcement

Collapse
No announcement yet.

Alternative to lookup

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

  • Alternative to lookup

    Sorry for the obvious question.

    Is there an example/tutorial/video etc. of using a popup form instead of the select drop down? I have a large table to search and and link from an existing form. I need a more robust search capability. Other ideas welcome.

  • #2
    Ah that's not so difficult. Just create a grid of the table you want to select from. Then create in your master application a caption link on the field you want to this grid form. In the link you can declare the link properties to modal and apply the size of the popup. That's all. If you click on the icon your grid will popup and contains a select button on every row. You can hit search to find a certain record. Also you can set the search in the grid initially, then the popup will contain the search screen initially and after search the grid.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      So simple!! Thanks for your help. Just thinking about the code to reproduce this is mind bending. My client thinks I'm a genius.

      Comment


      • #4
        That works really great, but . . . I am returning the unique id. What I'd like it to do is show the customer name the way that a select would on the id. I tried changing the field to a select but then the capture link disappears.

        Comment


        • #5
          Just fill the lookup part on the field to select the customer name.
          Albert Drent
          aducom software netherlands
          scriptcase partner, reseller, support and (turn-key) development
          www.scriptcase.eu / www.scriptcase.nl

          Comment


          • #6
            Well that's embarrassing, but thanks.

            Comment


            • #7
              I didn't think of this solution to my problem.
              i love to use this but instead of getting single value i wold like to get multiple values in a comma separated values, is it possible ? please say yes

              Comment


              • #8
                You can, but not this way. You need to apply an (ajax) event and put your select code there.
                Albert Drent
                aducom software netherlands
                scriptcase partner, reseller, support and (turn-key) development
                www.scriptcase.eu / www.scriptcase.nl

                Comment


                • #9
                  can you explain the way in more detail please ? do i still use the capture link ?

                  Comment


                  • #10
                    No, you just create an event on a field. Suppose you have a personnel number and want to display the name, address and phone number. Then you create an ajaxevent onchange on the field number. In this event you write a small script to retrieve the other fields by number and put them in the form variables. That's all. But you cannot combine events. If you have a capture link then the onchange event on the field probabely is not firing, it one of the issues we had. Then you need to be a bit inventive by using an onenter on the first focus field.
                    Last edited by aducom; 06-03-2013, 04:53 PM.
                    Albert Drent
                    aducom software netherlands
                    scriptcase partner, reseller, support and (turn-key) development
                    www.scriptcase.eu / www.scriptcase.nl

                    Comment


                    • #11
                      Thanks aducom
                      I am sorry perhaps i didn't explain what im trying to do right.
                      i want to select multiple records from another table (same as what you will do with multi select) but with a better way and more advanced search.
                      ex: i want to display a grid with a check box next to each row and after i select the desired records i save the values in a variable such as (1,5,65,854,25) and in the master form i do a lookup to get the description passed on the value (name,name3,name2)

                      Comment


                      • #12
                        You can create grids with checkboxes and process every selected record. But if it will suit you... I doubt it. I'm affraid you are going over the bounderies of the possibilities afaik.
                        Albert Drent
                        aducom software netherlands
                        scriptcase partner, reseller, support and (turn-key) development
                        www.scriptcase.eu / www.scriptcase.nl

                        Comment


                        • #13
                          Albert, I think mohammad has a point, i was looking into this because i have a similar case...

                          i have a multiple records form, one of the fields in the row need to be a select (double select) so user can select 1 or more values for the same field
                          - i have changed the sql type in db to "varchar" the only one could handle the multiple values as 1;2;3;4....
                          - now it is ok i have in each row a combo box in height 4 so 4 spaces are reserved from the from to show left/right side of the combobox, but mostly i have selected 1 value only, so i have the cobmobox just displayed blank space for nothing...

                          what i am thinking of (i think mohammed is trying to say the same) is:
                          - to have single text box with small select button, that will give the capture link application to select the value..
                          - next, a small (+) button, so if user wants to add new value, clicks on that and gives him another text box with select button for the capture link..
                          - hence, we will make the user display and chose only how many values he needs, no more, no less, with less space cunsumed...

                          actually i see this in many websites (add line, if necessary) but i have yet not idea how to do it using sc

                          what you think guys?

                          Comment


                          • #14
                            hi again, this is exactly what i'm trying to explain... the functionality of the lookup of sc is the same idea i am trying to inquire for...

                            addplus.png

                            what you think?

                            Comment


                            • #15
                              Albert,

                              I'm using a capture link on a form. Everything works great when just looking up existing records. However sometimes the user needs to add a record if they don't find it. After they add the record I want to select it and return to the original form just as if they had hit the select button. Is there a way to control that? If not, is there a way to force the grid to position itself on the page that includes the record that was just added?

                              Thanks!

                              Ted

                              Comment

                              Working...
                              X