I am trying to create a custom Output Window for my software that is bound to my ViewModel. Usually in the past I have always used a TextBox and used the appendText() method to write to the Output Window. Of course with a ViewModel and trying to bind to a Textbox, it seems you can only Bind to the Text property. Below is what I am trying...
I have one table INVOICEDETAILS that contains a PRODUCTID among other things. I want to create a combobox that gets all possible PRODUCTID values from the INVENTORY table but save the selected value to the INVOICEDETAILS table.
I can fill in the combobox with the INVENTORY values via the DATASOURCE property, but what I can't figure out...
I am wondering if there is a way with WPF binding to set the value via binding plus tweak it.
For example I have the width of a border being set to the canvas that contains it:
Width="{Binding Width, ElementName=mainCanvas, Mode=Default}"
Because I am doing a border with rounded corners. the Canvas.Top and Canvas.Left for the border...
I'm not sure the best way to ask this question (sorry for the ambiguous question title), but essentially I'd like to set the MaxLength property on a TextBox using a value converter that is passed in a property from the data context, and the property on the passed-in property as the converter parameter. I'd like to do all this in a style,...
Hi, i have a List for storing my data, i try to bind its items to grid,listbox,textbox etc. but cant make it work well. Here is my code
class Survey
{
public int Id { get; set; }
public string Desc{ get; set; }
public List<string> Choices { get; set; }
}
.
List<Survey> _surveyList = GetList();
BindingSource _bindingSourceSur...
I don't have tons of experience with binding sitemap files to the menu control in ASP.Net and wanted to see if this was possible (without a lot custom plumbing).
I am using the CSS Friendly Adapters to get clean markup. I have the CSS already prepared to create horizontal navigation, where the top bar represents the main navigation, and...
I am returning to WPF after a year of winforms development and am trying to get my eye back in with a small project.
I am creating a simple 'Filename Textbox' which is a usercontrol with a textbox and a button ("...") which spawns the FileOpenDialog. On this usercontrol I have declared a dependency property of Filename which the Textbox...
Hello,
I've just come across this problem with my checkbox data binding. The scenario is:
When I initialize the user interface (start the application), the checkboxes are unchecked, although the property they are bound to is set to true. When I click the checkbox, the property is set to false, but the checkbox is still shown as uncheck...
Hello all.
I'm having a little bit of trouble sorting out the paging scenario with a gridview i.e. I can't get the bloody thing to show page, 2, 3, 4, etc.
I have the following Grid view code
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
style="z-index: 1; left: 20px; top: 440px; position: abs...
All,
I have what i think is the simplest example possible of data binding in silverlight... but clearly even that is too complicated for me :)
The XAML:
<UserControl x:Class="SilverlightApplication1.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xam...
I'm writing a desktop application in Visual Studio 2008 / C#
I finished (mostly) writing an engine which generates a working schedule for the week for a small company; a form of a course-scheduling problem
Right now I'm designing a form in which the user can determine the initial parameters, or criteria, for the engine to adhere to (as...
My Custom UserControl's dependency property will bind correctly if the value is statically defined in the XAML calling it, like this:
ItemTypeIdCode="addresses"
but not if the value is bound dynamically itself:
ItemTypeIdCode="{Binding ItemTypeIdCode}"
What do I have to do to my custom UserControl so that it's dependency property r...
I have this strange problem all day now. I dunno if you handled something similar.
I used two different serializers and now i know its not this problem.
Im sending some data over TCP Sockets. Serialize -> Send -> Deserialize,
everything works ok, i can get my objects search through them, use they're properties!
But, if e.g receive a Bus...
I have an application that is in mfc with a very rich domain object, but I am not sure how to setup the databinding with the cformview. How do you deal with databinding? Are you ussing the DDX and DDV or do you have a better trick?
...
I have ItemsControl in a WPF application, which is bind to an array of objects.
And I am using ItemTemplate to render the list.
I want to display for each item in the list the item order, like for example
Customer 1
Name : xxxxx
Age: 9999
Customer 2
Name : yyyy
Age: 8888
Any idea how to do it
Thanks
...
I have a DataGrid component that I would like to update every 5 seconds. As rows are being added to this DataGrid I noticed that every update causes it to reset the scroll bar position to the top. How can I manage to keep the scroll bar at its previous position?
...
I hope i can explain this in few words, i m designing a generic framework and one of the things that came to my mind is there any way to know reverse binding information from a model property. For eg.given below Stock class
public class Stock
{
public string Symbol { get;set; }
}
Now lets assume that symbol of above model is binded to...
So, lets say I write a binding in Silverlight that cannot be resolved.
I get a message in the output window:
"System.Windows.Data Error: BindingExpression path error: ...."
Is there a way to get notified when this happens? Ultimately, I'd like to throw an exception or something. Is this somehow configurable?
...
I have a collection of Database objects, each containing collections of Schema objects and User objects. I want to bind them to a TreeView, but adding additional static levels in the hierarchy, so that the resulting TreeView looks more or less like this:
<TreeView>
<TreeViewItem Header="All the databases:">
<TreeViewItem Header="Db1"...
I am doing some WinForms coding for the first time and am trying to use data bindings.
I have a listbox which I bind to an array of strings from my controller object and I also want to bind the SelectedItem from the list box to another string property on the controller so I can track it.
listBox.DataSource = controller.ItemNames;
listB...