Search Results

Search found 2 results on 1 pages for 'costin'.

Page 1/1 | 1 

  • WPF Databinding problem

    - by costin
    Hi, I'm new to WPF and I have some difficulties when I'm trying to populate a ListView with a list of custom objects. internal class ApplicationCode { public int Code { get; set; } public IEnumerable<string> InstrumentCodes { get; set; } } I have a list of ApplicationCode which I set to ItemsSource to a ListView. I need to display the ApplicationCode.Code as a string and for the rest of the columns a check box which can be checked/unchecked depending if the column name is contained in the InstrumentCodes collection. In order to set the check box I use a converter on databinding: <DataTemplate x:Key="InstrumentCodeTemplate"> <CheckBox IsEnabled="False" IsChecked="{Binding Mode=OneTime, Converter={StaticResource InstrumentSelectionConverter}}" /> </DataTemplate> The problem I have is because I can't know which is the current column at the time of cell data binding and I can't set the ConverterParameter. public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { ApplicationCode appCode = value as ApplicationCode; return appCode != null && appCode.InstrumentCodes.Contains(parameter.ToString()); } There is a way to find out the column index or name? Or there is another way to solve this problem?

    Read the article

  • CompareValidator issue on Firefox

    - by costin
    Hi, I need to validate a date in a web forms application. For this I use a CompareValidator with Operator="DataTypeCheck" Type="Date" The problem is that this Validator doesn't work properly on Firefox with 2 digit years. ( javascript error: m[2] is undefined) With a 4 digits year it's working properly. This problem is described also here: https://connect.microsoft.com/VisualStudio/feedback/details/355573/comparevalidator-client-side-bug-two-digit-year-in-mozilla-based-browsers-throws-js-exception Does anyone know a nice workaround for this? Thanks

    Read the article

1