binding

How do I sort an NSArrayController by string length using bindings?

I'm trying to use a key-path to sort an NSTableView by the length of each string contained in each row. I'm using an NSArrayController to control my content array, but I'm having trouble finding out where or how to get the array controller to perform this behavior. I know the setting is in Interface Builder somewhere; I just can't find i...

Silverlight 4 custom control binding order is different when inside ContentControl.

I have a custom container control that has a number of dependency properties. One of which requires element binding. Most of the controls logic is within the OnApplyTemplate() method. When I test my control inside a normal panel or ItemsControl, everything works fine. However if the control is placed inside a ContentControl (which it...

Why is IronPython 2.7 throwing an exception when I create WPF bindings from XAML?

I've just installed IronPython 2.7 with VS support, and am trying to create a simple prototype WPF application. Something is broken, probably in my installation, and I can't figure out how to diagnose it. I can't get the simplest of bindings to work; they fail with an exception that seems really, really wrong. I create a WPF applicat...

Removing time stamp while assigning(binding) a date to text block in silverlight

i am facing issue to Removing time stamp while assigning(binding) a date to text block in silverlight t have been trying to do like this date.Text = date.ToString(); date.text is a text block and xaml code is in this case am getting output like date:2/2/2001 12:00:00 AM but i want output like date:2/2/2001 how can i do that? cou...

WPF Binding to objects.

I'm trying to reset data in my object bound to a simple form (some textboxes and a couple of buttons). I have 2 objects that were created separately, but have the same information. Object 1 is bound to a form using DataBinding. Object 2 is there to be able to reset Object 1 to original values. Whenever user edits data everything is fine...

Convert string to model

Let's say I have this object: public struct Line { public string Name { get; set; } public int Value { get; set; } public string Alias { get; set; } } And I have a file with lines following this syntax: garbagedata|moregarbagedata|Name|garbagedata3|Value|garbagedatamaximums|Alias\n Note that moregarbagedata[x] may or ma...

custom button control WPF

Hi, i want to make a custom button using wpf. The button will be used to control a mediaplayer. the type(play, stop, pause,...) of the button is specified using an enum namespace vgtunesWPF { public class MediaButton : Button { [Browsable(true)] public Button_Type ButtonType { get { return (Button_Type)GetValue(Butto...

Silverlight - How to bind data to a Control Template

In my App.xaml file I defined folowing Control Template : <ControlTemplate x:Key="PushPinTemplate"> <Grid> <Image Source="Images/konzum.png" Width="35" Height="35" /> <TextBlock Text="{Binding numberOfChildren}" /> </Grid> </ControlTemplate> And in my Main.xaml.cs file I'm adding Pushpins to a B...

How can i change the default values of the Binding Option in WPF?

In my current project i'm using several textbox controls whose content is filled from objects which are coming from a database. The object uses validation to validate the correct insertion of the text. When i want to show a validation error (i.e. the text has to many characters) i have to add some binding options to the text property li...

WPF bind to datagrid from template

hello, i'm new in wpf. I have a DataGrid form wpftoolkit and i need to show button in template only when row is selected and the record is not last(new record item) <dg:DataGrid AutoGenerateColumns="False" DockPanel.Dock="Top" ItemsSource="{Binding Source={StaticResource Entries}}" Name="dataGrid" ...

Event Handler access context JavaScript

I have a question in JavaScript context. I'm a little confused by this issue. The code below describes my question: $(..).someFunction{ var outOfScope = "OUT OF SCOPE!"; $('somelink').click(handler); function handler() { alert(outOfScope); } } My question is: how outOfScope variable (which was defined outside the handler...

How are "out parameters" represented for Seed JavaScript GObject bindings?

I've just started using Seed for development. One thing that Seed's web page mentions is that it "Maps C-isms (say, out arguments, or enums) to things that make sense in JavaScript." Unfortunately, I can't find any documentation or examples for how out arguments should work. So, for example, the following call in Seed: window.get_size()...

unbinding keydown jquery

I have created a method where you press the left and right keys and it goes from either the next or the previous page. the problem is that once you change it to another album the keypress methods are still bound to the previous album so you press the right key it will change the image in both the current and previous albums. I have tri...

Binding to a Guid on a DataView

Hello, first post here but I'm a frequent visitor =) I have a WPF application with .NET 4.0 and Visual Studio 2010 which uses DataViews (coming from an SQL Server 2008). I have two tables which looks like this Table1 GUID (Primary Key, UniqueIdentifier) Table2_GUID (UniqueIdentifier) Table2 GUID (Primary Key, UniqueIdentifier) ...

wpf binding 2 properties of 2 classes

Hello, I have a XAML-object (window-control) having his own-properties in the code-behind (in my case it has a property called 'FirstEditableDate' without any UI-binding). I also have another XAML-object (user-control) with a property (also without UI) and I want to bind the other property to this property. So, if the property of the ...

Jquery: Binding change to multiple checkboxes

For a little bit of background, I have multiple checkboxes, each weighted with a different "score". When the checkbox is changed, I need to compute the score. I thought something like the following would work but it does not look like the .change event is being bound properly. $(document).ready(function() { bindSomeCheckboxes(); }); ...

ColdFusion & Ajax: How to Get Blank Row in Binded Select Box?

I have two cfselect boxes that use binds and a cfc. One is State. Choose a State, and the second cfselect (counties) is populated on the fly. Prior to doing this with the bind attribute, I relied on the queryPostion="below" attribute such as the following to basically put a blank row into the option box. I want to do the same thing f...

Actipro property Grid show/hide properties

Hi, I am Using Actipro version 4.5.0485 property grid. i have a requirement to show/hide properties if a checkbox is check. i was able to do this by applying filters. but then i need to refresh the property grid every time chexbox selection is changed. i am using selectedObject to populate the property grid. Can any one please help me ...

How to bind list to a controller

Hello everybody, How to bind a list to a controller? Code in my controller, HTTPGET and HTTPPOST : public ActionResult Client(string id) { List<Customer> Contacts = WebService.GetContactsOfClient(id); return View(Contacts); } [HttpPost] public ActionResult Client(List<Customer> custs...

How to obtain the selected item after Listview Binding ?

I have a ListView and it's getting updated every 5 seconds. The problem is that the selected item vanish. How can I obtain it ? ...