AutoCompleteBox with SQL Query
Is it possible to use 'SQL Query' to get data for an AutoCompleteBox in a Form control?
Is there a way to use the RuntimeModifications to set the Input Data?
I have seen forum topics that can use SQL Query with ComboBox or ListBox and I can get those to work fine, but I need autocomplete. http://support.geocortex.com/SupportForums/Thread.aspx?pageid=0&mid=2&ItemID=20&thread=52447
OR could a combobox / list be set to jump to location in the list as user is typing.
-
Hi Mark,
The autocomplete control will run a query against ArcGIS Server each time a new character is entered, which is how it updates the list based on what the user is typing. Unfortunately I don't believe you can change this behavior to use a pre-populated list of items, as the way it updates the list is by rerunning a query. You could publish the database table that you are querying to ArcGIS Server as a Table, in which case it would get it's own Query endpoint which you could reference in the autocomplete control.
-Victoria
0 -
Thanks Victoria,
That is a great explanation of how the autocomplete works. I did not really want to go down the table in arcgis server path. Looks like I will have to set up some secured map services to cater for a few of the searches that I need.
0 -
Hi Mark,
It turns out there is a way to populate form item controls from a database table without needing to publish it to ArcGIS Server. I was only recerntly made aware of this feature.
You can set up a Data Connection in Essentials Manager to your database, and then go to the Tables section and create a Search Table that will return the correct information from the database. Search Tables now have a query endpoint that can be accessed by form controls, so if you set the Query URL in you workflow to http://server/Geocortex/Essentials/REST/ sites/SiteID/searchtables/SearchTableID/query , and then the Where clause to name1=value1&name2=value2... , where name1, name2, etc are the names of the parameters to your search table, the autocomplete should work.
-Victoria
0 -
Sounds perfect. It is morning over here so I can test it out today.
0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
4 Kommentare