none
HTML Client Auto-Execute Query RRS feed

  • Question

  • In the Silverlight client, screens based upon a query had an option to auto-execute the query when the screen was loaded.  If this was unchecked, the query was executed programmatically via an added button method using:

    <thisQueryScreen>.Load();

    With the HTML client, auto-execute is the default and no option is available to select in the properties pane.  Does anyone know how to disable the auto-execution of the query to replicate the similar functionality found in the Silverlight client?

    Sunday, April 21, 2013 4:52 AM

Answers

  • Hi,

    Unfortunately changing the auto-execute behavior is not supported in this release of HTML Client.

    Thanks for the feedback, I will log your request for consideration in future releases. It would be great if you can provide more information around your scenario that requires this feature.

    Best regards,
    Huy Nguyen

    Monday, April 22, 2013 5:41 PM

All replies

  • Hi,

    Unfortunately changing the auto-execute behavior is not supported in this release of HTML Client.

    Thanks for the feedback, I will log your request for consideration in future releases. It would be great if you can provide more information around your scenario that requires this feature.

    Best regards,
    Huy Nguyen

    Monday, April 22, 2013 5:41 PM
  • The browse screens return a large number of results in my query, and the Load() method would have been helpful in filtering them before display.  I am experimenting with the filter pop-up that Beth Massi had in one of her video demonstrations as well as just having a default selection filter parameter when the screen is loaded that the user can change.
    Tuesday, April 23, 2013 8:01 AM
  • Thanks for the information.

    Yes, in your case you can customize the screen's collection property and add parameters to restrict the results. You can start by drag/drop the parameters on the screen as text boxes. And you can initialize the parameters using the local properties generated on the screen. For example:

    myapp.BrowseCustomers.created = function (screen) {
        screen.Country = "France";
    };

    Best regards,
    Huy Nguyen

    Tuesday, April 23, 2013 4:06 PM
  • The browse screens return a large number of results in my query, and the Load() method would have been helpful in filtering them before display.  I am experimenting with the filter pop-up that Beth Massi had in one of her video demonstrations as well as just having a default selection filter parameter when the screen is loaded that the user can change.

    With the Silverlight Client, a lot of the time, there are a bunch of collections sitting on the screen. It was important that some of them not auto-execute if a collection one were dependant on changed.

    With the HTML Client we show only what we need.


    The Visual Studio LightSwitch Marketplace

    http://LightSwitchHelpWebsite.com

    Tuesday, April 23, 2013 8:27 PM
  • Hi Huy, I saw this thread after posting http://social.msdn.microsoft.com/Forums/en-US/lightswitch/thread/b7a0209f-f9b2-46a2-b02e-1b62b1219e3e. Actually my questions is the same as AllenAdam's.

    As a scenario, say you have 3 optional parameters for first name, last name and city. The table has millions of records. The user wants to filter people with a specific last name in a specific city. But in the current html client, after entering a value in the last name textbox and leaving it for entering a city the table is filtered immediately only on last name column. This executed query is unnecessary for now.

    Only after entering the city value the intended query should run for the customer, which filters the huge table by last name and city.

    Thanks

    Monday, May 6, 2013 11:34 AM
  • The browse screens return a large number of results in my query, and the Load() method would have been helpful in filtering them before display.  I am experimenting with the filter pop-up that Beth Massi had in one of her video demonstrations as well as just having a default selection filter parameter when the screen is loaded that the user can change.

    With the Silverlight Client, a lot of the time, there are a bunch of collections sitting on the screen. It was important that some of them not auto-execute if a collection one were dependant on changed.

    With the HTML Client we show only what we need.


    The Visual Studio LightSwitch Marketplace

    http://LightSwitchHelpWebsite.com

    Hmmm. If we do not want to use paging, we are left trying to load an entire table in query results when the screen is created. It would be a great feature to still have in the HTML client.

    I got around this by making a boolean switch required as 'true' in order to meet query criteria. This way you have time to build your query, then turn the query 'on' by using the required 'on/off' switch. It is a bit clunky.


    • Edited by CreedCor Monday, October 31, 2016 7:48 PM
    Monday, October 31, 2016 7:43 PM