How to create auto-update dependent dropdown list? - dropdown

I have a great task with creating auto-updating dependent dropdown list. I have a long list of fruits and long list of vegetables, which again may keep adding. So the reference dropdown would be selecting fruits or vegetables.The dependent dropdown should have the list of the previous selection. The problem here is the list gets updated so often, so I cannot give any fixed reference of the list. Also the list of fruits need not be the length of the list of vegetables, which when including a fixed reference column leads to the display of zeros in the drop-down taking into account the empty cells.
Please help me through this issue. Thanks in advance.

Related

How to make two product columns for a specific collection in shopify?

I am trying to change the number of columns for a specific collection. Right now collection is set to four columns but i would like the one collection to be only two columns. How would I do this?
clone the current collection liquid with 4 columns
edit the clone file to have only 2 columns
Assign this new 2 column collection some products
hook up this collection with 2 columns to navigation
In other words, assign your specific collection a different collection template, one with 2 columns.
You would need to adjust the css class for the grid on the collection page. Every theme is different so there is no clear cut answer. Typically you would need to open the collection.liquid section file and look for grid_item one-quarter or something similar and adjust to grid_item one-half.
If it is a Shopify Free Theme you can reach out to their support team and they usually are able to help you with it.

Access VBA code for copying information from a combobox and pasting into a textbox on a continuous form

Really need help with this, I have a continuous form with a combo box to choose data, each row has a different criteria and you can choose only certain items per row in the combo box drop down. (As an example I have four rows one is a cap, one is a bottle, one is a label and the last is oil to go in the bottle.)
What I need is when I have chosen something in the combo box drop down I want it to paste into a text box and stay there until another choice on the same row is made...... Currently I can make the information appear in the textbox but then when I move to another row and choose anothe item it over writes anything I have already chosen.
So an example would be I have chosen product 1, it has cap 1, bottle 1, label 1 and oil 1. In the drop down combo box I can choose only bottles to replace bottles caps to replace caps and so on. I want to choose bottle 2 in the combo box on the bottle line (Which changes all the combo boxes) I now want to save that choice in the text box on the bottle row only, then when I choose Label 2 on the label row even though it changes all the combo boxes I don't want it to overwrite the text box for the bottle row. (I'm assuming a criteria that will only change the row of the combo box you are clicking on or something like that)
hope this makes sense to every body (P.S. I don't know how to get a screen shot in here so have tried to explain to the best of my ability)
Many thanks
Justin
You have to bind the textbox to a field in the record.
As long as the textbox is unbound, it doesn't know about a record and will display the same for all records.
I'm making the assumption that you want to be able to map some product to 4 different types of caps, bottles, labels, and oil:
It seems that your problem is in your data table design, not in your comboboxes. You shouldn't need the text field at all. The problem is that your comboboxes are all based on the same table. When you select Bottle2 from one of them, it matches the rest of the comboboxes to that row. So all the others will get Label2, Cap2, etc. because they are in the same row of the table.
Make a products table call it tblProducts. The fields ID (autonumber), product_name, label_FK, cap_FK, Bottle_FK, and oil_FK should be in it. Those FK stand for Foreign key and should be a number type. The product name can be text.
Create the tblLabel, tblCap, etc. with an ID, and a description.
In your relationships you need to map the tblLable.ID to the tblProducts.Label_FK field. Do this for all 4 type. Then you can re-create the form based on the products table. Whatever the form gives you for the way to control the label_FK, cap_FK, etc. fields you can convert it to a combobox by right click -> change to...
Finally, you may need to update the number of columns of the comboboxes in order to see the description also.
EDIT: More lasting information -
Doing some solid research on data table design will pay huge dividends in design time. Starting with the Database Design Basics page from Microsoft will help as a decent 30 minute intro and should help clear some things up for you.

creating a ComboBox in MS Access to hold distinct types

I am trying to create a combo box in an Access form to display all the types in an inventory list (ex. cables, UPS, shelves, ...)
When I make the row source for the ComboBox I only want the type to display there once. The ComboBox will later be used to make a report for the different types of items in the inventory, so I will only need each type in the list box once. These types can be changed later so I want the list to be updated automatically.
Right now I have the ListBox displaying all the types multiple times, but when I try to change the row source to:
Select Distinct Inv_Type
From Inventory;
I just get an empty ComboBox. But when I query that code I get get each type only once (this is what I want). What am I doing wrong? Why am I getting an empty ComboBox?
Doing as what Remou said; I created a ComboBox from scratch, without using the wizard first fixed my problem. Thanks!

How to filter a Sharepoint List Column with a Textbox Control Value using a "Contains" query?

I'm using a data view to display a list (Sharepoint 2010) that has several columns including one that has a Name column. I've provided the user with a text filter on the page to send values to filter the Name column in this list. The problem I'm facing is that the filter only works for exact matches and not partial matches.
I tried to overcome this problem by using Sharepoint Designer to:
create a parameter that uses the textbox control value.
Filtering the Name column with this parameter and setting the comparison to "Contains"
Unfortunately if the default value of the Parameter is blank, the list does not display any data. If the default value of the parameter is set to part of a name in the list, the list displays names that contain that string. However, when changing the value in the text box and searching, the list does not return results. Please let me know if you guys know how to fix this. Any help is much appreciated and let me know if you need any additional information. Thanks!
Managed to find a solution to my problem. I used a custom javascript solution designed by jvossers (http://instantlistfilter.codeplex.com) that involves the list being filtered instantly much like Google's search!
The only downside of this solution is that it only filters the items currently displayed on the screen. Therefore, if you have a data view web part which limits the amount of items displayed on the page, this solution won't help you. In order to facilitate this solution, display all the row items on the page (by increasing the item limit per page to a larger number than your total list rows) and then add this code into a content editor web part on the same page. Worked brilliantly for me. '
By the way if you are using jQuery 1.3.x or higher, you should modify the script a little as described in the disscussion here: http://instantlistfilter.codeplex.com/Thread/View.aspx?ThreadId=49123

Access multi selection list box as a criteria to INSERT, UPDATE OR DELETE records from a table

For a database with this schema (a product may belong to one or more categories):
Item_category(product, category_name)
Category(category_name)
Will it be possible for me to build a multi-selection list box (List box data source from the Category relation) using an Access form and then highlighting the categories that the product belongs to (by querying the Item_category table), and at the same time letting users select new categories or deselect highlighted categories so that when an "Update" button is pressed, VBA code will automatically determine either INSERT, UPDATE or DELETE queries are needed to update the Item_category table?
How can I do that? Thanks!
I've generally done this type of interface using a form which looks very much like the "Which fields do you want on your form?" in the Form Wizard. Where you have the Table/Query list of Available Fields in the table in the listbox on the left hand side and the Selected Fields in the listbox on the right hand side. Along with the move left and right command buttons in the middle. The users quite like this interface.
Added: Note that the left hand listbox contains all the category records which aren't present in the products category table. So a category would be present in one or the other listbox but never both.
You very likely will want to use the Multi Select property of the listbox. If you hit the help on that field in the property sheet it should lead you to a page which mentions the ItemsSelected collection. Visit that page for sample code on how to read all the items selected by the user. Or visit http://msdn.microsoft.com/en-us/library/aa196172%28v=office.11%29.aspx.