c# - Change WPF ListView SelectedItem binding value -


When I double click on a line, then I am trying to change the compulsive value, Have seen through the medium but I did not find anything that I need.

Here's my code and the example is how I want to work. Is it possible to edit a line bidding value in a listview like this?

WPF:

  & lt; ListView x: name = "LstLinks" horizontal alignment = "left" height = "108" margin = "10,53,0,0" vertical alignment = "top" width = "641" selection mode = "single" & gt; & Lt; ListView.View & gt; & Lt; GridView & gt; & Lt; GridViewColumn Header = "G" Width = "20" DisplayMemberBinding = "{Binding LG}" /> & Lt; GridViewColumn Header = "P" Width = "20" DisplayMemberBinding = "{Binding L.P.}" /> & Lt; GridViewColumn Header = "Link Type" Width = "100" DisplayMemberBinding = "{Binding LType}" /> & Lt; GridViewColumn header = "code" width = "60" DisplayMemberBinding = "{binding LCode}" /> & Lt; GridViewColumn Header = "Company" width = "150" DisplayMemberBinding = "{Binding LComp}" /> & Lt; GridViewColumn header = "name" width = "150" DisplayMemberBinding = "{binding LName}" /> & Lt; GridViewColumn Header = "Address" width = "137" DisplayMemberBinding = "{Binding Ladders}" /> & Lt; / GridView & gt; & Lt; /ListView.View> & Lt; / ListView & gt;   

C #:

  Zero LstLinks_MouseDoubleClick (Object Sender, MouseButtonEventArgs e) {var selItem = LstLinks.SelectedItem; //selItem.LP = "A" ??? "; Lt; LstLinks.Items.Refresh () can not be done;}    

You can not change the bond of a line, you can change the bond of the column only if the row is created.

The code provided by you, your Assuming the binding values ​​to be correct, will work with the changes made by Sajeetharan. Since you have not given us any information about our class, we will You can not say to make sure that your special sample will work.

In addition to this, I would like to suggest that the property be applied and provided that which is giving notice of change, .

Comments

Popular posts from this blog

Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -

multithreading - PhantomJS-Node in a for Loop -

c++ - MATLAB .m file to .mex file using Matlab Compiler -