How to bind non-existing IsEmpty property of listbox?
Hello, I have a form and a button should be enabled only if the listbox is not empty. How can I do binding for this case? Note: I would like to avoid creating custom converter. Thanks! ...
Hello, I have a form and a button should be enabled only if the listbox is not empty. How can I do binding for this case? Note: I would like to avoid creating custom converter. Thanks! ...
Hi Trying to understand this binding process of the WPF. See the code at the bottom. In my "viewmodel", see the code at the bottom, i have an observable collection that is populating the listview with the items. Thats the one that contains a path called symbol to set the selected index in the combobox. Now my problem is that i need to...
I find myself often faced with this problem: I have a dictionary where the key is some simple numeric ID and the value is an object. The ID is also contained in a specific property of that value object. Then, I want to be able to deserialize some (format-inflexible) XML that looks like: <listitem> <id>20359</id> <someotherval>f...
I have a Formview binded in the code file to a generic list. Now, upon editing of a record, I wish to access the Keys and NewValues out of the FormViewUpdateEventArgs parameter of the ItemUpdating event handler method. From what I've tried and searched over the internet as of now, I've come to know that updated values are only available...
Hey all, I am creating a wpf application and am having a little difficulty implementing an user interface idea I have. I have a MasterViewModel bound to the MainWindow which exposes an observable collection of ViewModels. I have written some commands that essentially switch the current view model in the observable collection and this s...
Hi. I was having problems inserting a string into the following tag : <tr id="rowBulkOptions" style='<%# sBulkOptionsRowStyle %>'> Don't ask why I'm using tables :) sBulkOptionsRowStyle is a Public string in the aspx.vb file. Seemingly the only way I can get this to render is to put Page.DataBind() in the Page_Load, Page_PreRende...
This is related to Classic ASP code. A page fetches data for a particular ProjectCode. There is a general text field which shows the Site-Location for selected Project-Code. I want to change it to drop down, so that a user can change the Site-Location from options available (fetched from DB) and then save it. Also, on page load the Sit...
Is there a control in silverlight to group controls together for data binding. For instance, say I have a Person object and I want to display fname, lname, age, height, etc. in TextBlocks. Is there a control I can use to group these TextBlock controls together and set the ItemSource on just that control similar to how you set the ItemS...
This is what I am trying to achieve : 1)DataTable populated using data from non database source 2)This table is bound to a DataGridView using BindingSource 3)The DataGridView is updated by the user, so that some cells now have new values. 4)Because the table is bound to the datagridview its values are updated. How do i get only the updat...
Hello all, An easy one ;-) I declared: xmlns:om="clr-namespace:System.Collections.ObjectModel;assembly=System" I try to set a generaic as the DataType: <DataGrid d:DataContext="{ d:DesignInstance Type=om:ObservableCollection<System:Int32>}" /> But I'm receiving an error: "Invalid format for a type". Anybody ha...
I have a DataGridView bound to a BindingList (C# Windows Forms). If I change one of the values in an item in the list it does not immediately show up in the grid. If I click on the changed cell, or minimize then maximize the window it updates properly, but I need it to happen automatically. I had the same problem earlier, but in that si...
Hi all, Could anyone please enlighten me about how one might go about binding to a gridview in ASP.Net 4 in a scenario where the first row of my gridview should be the headers, the second should be a combobox for each column and the third is the beginning of my actual datasource. If you can imagine what I am trying to achieve is an abi...
Hi. I am currently experimenting with WPF. One thing, I wanted to do was a master to detail selection over multiple comboboxes. I have a ViewModel with GroupItems that i use as ItemSource for the first combobox. These GroupItems have a Property called Childs, which includes a List of items that belong to this group. I can't find a way t...
I have a StringCollection that I want to One Way Bind to a ListView. As in, the ListView should display the contents of the StringCollection. I will be removing items from the collection programatically so they don't need to interact with it through the ListView. I have a Form with a Property, like so --> public DRIUploadForm() {...
Basically, I am confused about how to implement databinding on the control side. I am trying to write a custom list control in C#, which implements databinding. I want it to end up having similar functionality to the ListView, but with an interface similar to ListBox. I have a private nested class called "ListRow" which handles render...
I have a simple application which uses a BindingList<(Person)>, people, to store information about employees (Windows Forms). Person has several properties such as Name, DateOfBirth, etc and implements INotifyPropertyChanged. The BindingList<(Person)>, people, is bound to a binding source. A DataGridView control is bound to this source,...
I'm trying to provide a simple way for our users to select a desired shipment method (ie: UPS ground) without having to know it's corresponding ShipmentMethodID. There are three key aspects of every shipmentmethod that uniquely identify it: Courier (ie: UPS, FedEx, OurTruck, To Be Determined) Service (ie: Ground, 2Day10am, To Be Dete...
I'm using the following code to add a target binding to a NSButtonCell control: [dataCell bind:@"target" toObject:eventDatesArray withKeyPath:@"selection.self" options:[NSDictionary dictionaryWithObjectsAndKeys:@"sellTicket:", NSSelectorNameBindingOption, nil]]; eventD...
I have a Silverlight application which uses 2 separate databases. I have a situation where I have an Id column in one database, and the lookup table in another database. Obviously I cannot enforce this as a foreign key, and the Entity Framework will not let me build a single Entity Data Model for 2 databases, so I cannot define this rela...
Hi, I am using ZK framework to develop web applications. I am using databinding on components to set and get values. I can register databinding in source ZUL file and also in the method doAfterCompose in page's controller. This method is called during page composition. But now I have to add a new component and it's databinding into exis...