I have created a combobox in orca but I'm unable to give a default value to the combobox, btw the combobox is in replacement of a checkbox control and I have also tried changing the default value in the property table of orca. Please let me know if there is any other method as the above is not working.
Thanks
Windows Installer doesn't have a "default value" concept for the combobox. You would have to have a set property custom action to set the property to the value (Not text) of what you want to be default if the property does not already have a value ( Not PROPERTY ).
Related
I am trying to figure out how to add placeholder string value on every property inside a property grid that was not changed from the user.
So let's say you are trying to edit some object when you get prompted to do so you will get the following form.
If you changed the color property for example the result would be the following.
I tried to see if there is an attribute but it seems that there is not. DefaultValue is not suitable because the message is a string and the underlying property could be anything.
The question is if this is possible using combinations of Editors and TypeConverters.
Thanks.
I have a view that contains several ComboBox elements. For some reason old data remains from the previous time the view was opened and I would like to reset the combobox elements in the view every time it is opened. Is there a function that could that for me? I want it to be exactly how it is as if I rendered it the first time with the initial items. Would using setSelectedItem(vItem), setSelectedItemId(vItem), setSelectedKey(sKey), setShowSecondaryValues() help? If so, what do these keywords mean (selectedItem, selectedItemID, selectedKey, secondaryValues)?
Unfortunately you do not provide an example. Normally you bind your UI controls against a model, e.g. JSONModel. In this case the items of your ComboBox controls would be taken from the corresponding model. However, you can use method removeAllItems to achieve the desired behaviour.
UPDATE: Obviously the controls are bound and only the selection should be cleared.
Use setSelectedItem with value null to clear the selection. You could also use the binding to set the selected item automatically by using the selectedKey attribute, see example.
I have created a custom control with new dependency property (TagToSet) of type MyTag(id, name, value).
After adding this control to my window design, and going to the properties to set the value of the new dependency property. Here I want to open a dialog to select the Tag that I want (like the case when the dependency property is collection).
note: the Tag property is not a collection, and the required dialog should connect to a WCF service to list the available tag.
Thanks
Ok, here is the start key Microsoft.Windows.Design.PropertyEditing
for those who are trying to do like me read this
article
In my form I have a Barmanager, in which I have a comboboxedit1. I want to know how to access to the selected item of the baredititem1 (combobox). In the normal combobox it is:
dim q =combobox1.selecteditem
but I can't do the same in a baredititem1 wgich is placed in a barmanager.
You can grab the current selected value using the barEditItem1.EditValue property, or while the editor is activated, you can access the current editor instance by BarManager.ActiveEditor property, which you should cast to ComboBoxEdit in your case. You can read about this more in the documentation, where they explain why you cannot access the concrete editor anytime you want.
I have a ComboBox and its items source is an SQL table.
I would like that the user will choose the value he likes and if the value is not in the list, he would be able to type the value into the ComboBox. Is it possible?
Thanks.
You need to set the IsEditable property of the ComboBox to True. This will allow you to edit the contents as well as select any of the populated items in the combo box.