I've hooked up a ComboBox's SelectedItemChangeEvent to a ICommand in my view model.
Everything seems to be working fine however I do not know how to get the SelectedItem of the ComboxBox.
I think I need to use the CommandParameter of the EventToCommand - do I bind this to something in my ViewModel
that has the selectedItem of the ComboBo...
OK I got a project that has a application layer, web layer and a data layer shared by the other two layers.
Now I have one part that is Hierarchical data that the application has to be able to look over, edit and add new to.
So at the top is Company wich can have many Divisions and each division has Employees & Production Licenses (tw...
I'm trying to bind a view model property to the 'SelectedItem' attribute of a WPF combobox. This combobox resides within a RowDetailsTemplate of a DataGrid. The binding is partially there because the view model's property getter and setter each get called once when a row is selected (And thus causes the details view to expand). However t...
I found a lot of posts that dodge this topic, but none that actually addresses this case.
I have a ComboBox bound to a List<State>, where State is a business object that has Abbreviation and Name properties:
this._stateComboBox.DataSource = ((Address)this._addressBindingSource.DataSource).States;
this._stateComboBox.DisplayMember = "Ab...
Hi All,
I am binding dataview to listbox. How to get the selected item.
Geetha
...
I am using the DevComponents TabNavigation control for WPF, and am able to add a new TabItem to the TabNavigation at a specific index, call it i, in the code-behind. Now I want to make the new TabItem the SelectedItem, by doing:
private void textBlock_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
int i = createNewTabI...
Hi All,
I want to scroll the listbox which is placed inside the srollviewer according to its selection.
ListBoxItem item = (ListBoxItem)(lbTrack.ItemContainerGenerator.ContainerFromItem(lbTrack.Items.CurrentItem));
// ListBoxItem item = (ListBoxItem)(lbTrack.ItemContainerGenerator.ContainerFromItem(lbTrack.SelectedItem));
...
I have a combobox in WPF like this:
<ComboBox Text="Select Language..." IsEditable="True" IsReadOnly="True"
ItemsSource="{Binding XPath=item/@name, Source={StaticResource Items}}"
SelectedItem="{Binding Path=Test, Mode=OneWayToSource}"/>
Where Items is:
<XmlDataProvider x:Key="Items" Source="/itemlist.xml" XPath="...
Hi,
Hope you can help me with this. In a Flex 4 app I have a List I use for navigation. When the user clicks on one item the application goes to the appropiate view. Now I want to do some validation before the user moves to the new view, so I wanted to prevent the item selection, make the validation and if it is OK change the selectedIt...
Im having a very funny issue in WPF
Im creating a Combobox through code, and adding it to a control.
When I set the Combobox.SelectedItem or Combobox.SelectedIndex or Combobox.SelectedValue I am unable to select another option from the Combox items.
ForeignKeyDisplayAttribute attribute = (ForeignKeyDisplayAttribute)this.GetAttribute(t...
Hi there,
I have 3 dropdown boxes (combo box) in asp.net environment.
They are all optional, so if a user has selected anything, i am updating database, if nothing has been selected at all, i am still updating database with null values.
I tried to do this:
int? CountryId = Convert.ToInt32(ddCountries.SelectedItem.Value);
I was hop...
Hi all,
I have a viewmodel which implement INotifyPropertyChanged. On this viewModel is a property called SubGroupingView. This property is bound to the selected item of a combo box. When i change the combo box, the source property is being updated fine, but when i change the source property or when the control is initialized, the combob...
I have a ComboBox that has its ItemsSource bound to a static List<CustomSettings> of options. The ComboBox is part of a form which is bound to a CustomObject class, and one of the properties on that class is a CustomSettingProperty.
I would like to bind the SelectedItem of the ComboBox to the property specified in the CustomObject, how...
Hi Guys,
Is there any way so that we can provide style to the Selected Row in DataGrid (SilverLight). I am able to handle SelectionChanged() even but there I found SelectedItem (BusinessObject) not Row so that I could provided it required backcolor/Forecolor.
I tried to achieve it by binding RowBackColor property of DataGrid with a con...
Hi I have a TreeView which is filled with a hierarchicaldatatemplate
<TreeView Name="DokumentBrowser" ItemTemplate="{StaticResource HierachrTree}"
<HierarchicalDataTemplate x:Key="HierachrTree"
DataType="{x:Type src:Ordner}"
ItemsSource="{Binding UnterOrdner}">
<TextBlock Text="{Binding OrdnerName}"/>
...
How can I send multiple row first column values to server in jqGrid?
Update 1:
my approach
jQuery("#wics").click( function(){
var ids =jQuery("#list10").jqGrid('getGridParam','selarrrow');
$.ajax({
type: "POST",
url: "/cpsb/unprocessedOrders.do?method=releaseTowics&orderNum="+ids,
data: JSON.stringify(ids)...
I have a List with objects of class Person. I have set the list as a DataSource of a ComboBox. Now when I set the SelectedItem of the ComboBox a new instance of class Person, the SelectedItem never sets. Why it happens?
public class Person
{
public Person(string name, int age)
{
Name = name;
...
the problem is that i have two listView but one itemClick method, if i put a switch, the position on one list is the same than the other list... And by example if i want to open a popup on an item in one list, the item in the same position in the other list gonna do the same thing, and i really don't want, can you help me?
Thanks
there ...
I am currently facing a problem. How to get the latest selected value from a asp.net checkbox list? From looping through the Items of a checkbox list, I can get the highest selected index and its value, but it is not expected that user will select the checkbox sequentially from lower to higher index. So, how to handle that?
Is there any ...
Alternatively, I could use something like viewWillAppear, only switching tabs doesn't call viewWillAppear - IF I can access selectedItem or selectedIndex reliably from there.
The goal is to re-use a similar table view, with 3 tabs filling the table with differently filtered data.
I tried overriding didSelect and using the app delegate ...