• Stephen Chen
    October 26, 2016 at 8:14 am #2944

    Hi,

     

    We created a input box to do search against a table.

    The table starts off empty, then we have a service to load the data from the database.

    The user will type in the keyword (ex. Cindy) to search for the person they are looking for.

    The search is against the first column as indicates in the OnInputScript.GIF

    However, the only valid keyword (only searchable word) is undefined (as shown in the SearchUndefined.gif).

    If any other word is typed, the table would be empty (as shown in the SearchCindy.gif)

    We are wondering that for some reason the static data is not being updated for the search function, so when the search function is being called, it can only detect Undefined.

    If that’s the case, is there any function we can use to refresh the static data for the search function.

     

    Thanks in advance

     

    SPARK Support
    October 26, 2016 at 8:40 am #2948

    Hi Stephen,

    I usually place the search function in the On Change event of a Text box:

    ${Table1}.search(0, me.getText(), true, true);

    In your example, I see “potential” for the expression argument.  How is this being defined?

    Also, which BPM and SPARK versions are you using?

    Regards,

    Stephen P.

    Stephen Chen
    October 27, 2016 at 5:03 am #2951

    Hi Stephen,

    “potential” is one of the keywords for On Input event. Essentially it is whatever the user typed in. I checked the output by using alert function, and it is exactly what I typed in. I tried the suggestion provided, and it has the same behavior. If the input is “Undefined”, all the rows  are shown. If the input is any other words, no row is shown. It is interesting that the search only reacts to word undefined. It makes wonder there is something missing so that the search function cannot find any word in column 0

    Thanks

    SPARK Support
    October 27, 2016 at 8:47 am #2954

    Hi Stephen,

    Can I take  a look at your implementation?

    Please upload your TWX file to the following directory:

    https://sftp.salientprocess.com/sharing/bWeTxRlCg

    Regards,

    Stephen P.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

Start typing and press Enter to search