Problem with jquery autocomplete multiple feild - autocomplete

basically I want there to be 2 input options. if you select the country in the first input option , the name of some City in that country will appear in the 2nd input option.

Related

Create entry in Access form based on entry chosen from combox box (without including the entry from the combo box)

I use Access to maintain a list (with details) of cases I work on (I am a legal professional). I want Access to add an unique case identifier to every case. I use a form to enter the data in the database.
I wrote this very simple code to add the Case ID nr:
Private Sub Command81_Click()
If Not IsNull(Me.Case_ID) Then
DoCmd.CancelEvent
Else
Command81.Enabled = True
Me.Case_ID = Me.Combo321 + Format(Me.[Date Original Event], "yymmdd") + Format(Time, "hhmmss")
End If
End Sub
The idea is I fill the different fields in the form and then click a button to add the case ID (listed in the textbox (in the form) and field (in the database) called 'Case_ID').
When I click the button it should check whether there is already a case ID. If there is it will not create a new one. If there is none a new case ID will be created based on the country where the case happened (Combo321) + the date when the original event happened + time I created the case ID.
The country where the case happened is choosen from a dropdown menu (Combo321). The options in the dropdown menu come from a table with a list of countries:
The Netherlands, United Kingdom, Germany, etc.
If possible I want to keep the list of (full) country names in the dropdown menu, but in the case ID use a 2 or 3 character abbreviation. So if I choose from the dropdown menu that the case happened in The Netherlands I would like the case nr to start with NL, if the case happened in the United Kingdom I would like the case Nr to start with UK, etc.
Is it possible in the table with the country names to make a second column with the abbreviations and then in the code somehow to have the case ID start with the entry in that 2nd column that 'belongs' to the relevant entry in the first column (the full country name) that I picked from the dropdown menu?
Or maybe there is another way of doing this?
Yes, create field in table. Then have that field in combobox RowSource (multi-column combobox). Combobox properties:
RowSource: SELECT CountryCode, Country FROM Countries;
ColumnCount: 2
ColumnWidths: 0";1.0"
BoundColumn: 1
ControlSource: field to save selected combobox value
Two-letter CountryCode will be saved into record if combobox is bound to field. It will also be used by your code.
Saving data dependent on other data is usually not necessary and often a bad idea. This identifier can be constructed by expression when needed for display.
Also, advise to develop habit of using nn for minutes instead of mm. It actually doesn't seem to make a difference in Format() function but I have seen usage where it does, although can't recall exact circumstances.

Filtering Based on a Different Column on Tableau

I'm wondering if something like this is possible.
Assume I have a data table like this:
I want a filter, where user picks France for example, but the data is filtered based on corresponding Continent value, e.g., all Europe records should show up.
Is this possible?
Sure, We can do that. If you add country to Filters shelf, Tableau will show only records of selected value. In our case, if we filter "France", Tableau shows only records which has France. So we will miss other Europe records. Parameter can handle this scenario. Follow below steps.
1.Create a String parameter
2. Create a calculated field
3. Add the created calculated field to Filters shelf then choose 'show'
4. Right click parameter then 'Show parameter control'. So it will works like filter
Method 2: Dynamically change parameter value
Pros: No hard coding, dynamically changes value based on selection. It works, well on dashboard
Cons: You will not have drop down for selection like filter. So, you need to click a chart to trigger the changes.
1. Create a String parameter with allowable values as 'ALL'
2.Create a calculated field
3.Create a parameter action in dashboard.
Dashboard-> Actions-> Add Action -> Change Parameter
In Change Parameter dialogue box, set target parameter as 'Parameter Name' and value field as 'Continent'
4. Add the calculated field to filter and select 'True' on other sheets
5. Final Dashboard looks like
Click the icon on the selector sheet. It will automatically filter data on data sheet.
Inside the selector sheet

Dynamic List Input control in JasperReport 5

I have 100,000 account numbers. I want to randomly give any 5 (as per my requirement. Could be 1 or 2 or 20) account numbers and see the information about them.I have tried the following.
I tried with string input control, cascading input control with one string and one list parameters. But none of them works.
1) String Input Control: I tried entering the 3 random account numbers comma separated. But my query dosent accept the same since I have to use a list parameter and $X variable.
($X{IN,acct_no,test}).
2) Cascading Input Control: I thought let me take a string input control and a list list input control and use the string input control within the list input control. So I tried like the following.
Created a parameter and an input control with string datatype (where I can enter comma separated account numbers). The parameter name is $P{account_no}
Created a list parameter and an input control with list datatype as an multiselect query using the string parameter as below. The parameter name is $P{test}
select account_no from customers where account_no IN ($P{account_no})
Note that I have used the first parameter.
This works fine for only 1 account number and not for 'n' account numbers.
I also tried something like
select account_no from customers where ($X{IN,acct_no,account_no})
For obvious reasons this does not work.
I am using Jasper 5.0.1
Is there a way to dynamically populate a list based on the input values.
Could anyone kindly let me know how to achieve my desired output?
Any help would be appreciated.
Many Thanks.
The following did the trick.
SELECT customer_name FROM customers where account_no in($P!{account_no});

How do I make one parameter dependent on another?

I need two parameters in my report. I know how to make them, but I need the 2nd one to depend on what the person chose for the first answer. For example, if you choose USA as a country, I need the second one to show only states in the USA.
How can I do that?
while creating a parameter.
select option as dynamic.
Then start selecting the database fields in parameters, First select country and then states
by clicking on the 2nd column you name the parameters.. you can change the name as you wish after clicking ok by using rename option.
Now place parameters in report of set parameters in record selection formula.
When you refresh the report you get parameters with dependency.

how to select grid columns by query button in telerik radgrid?

hello friends
i am displaying data in telerik radgrid and i want to add a autocomplete text box with query button to select the particular row using one column for binding.
Can any one provide me a hint?
it has been almost a complete day but im getting no help.
How about using the solution from here? There is a textbox in the command item which filters the records by specified column values (the column is chosen from a dropdown beside the textbox).