Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Of course im using it on two different positions here is the smallest:</p> <pre><code>&lt;UserControl x:Class="Unattended_Tool.View.UserControls.Admin.UserControls.Detail" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:dxc="http://schemas.devexpress.com/winfx/2008/xaml/core" xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid" xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors" xmlns:dxlc="http://schemas.devexpress.com/winfx/2008/xaml/layoutcontrol" mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="300"&gt; &lt;dxlc:GroupBox MinimizeElementVisibility="Visible" IsManipulationEnabled="True" &gt; &lt;Grid&gt; &lt;Grid.ColumnDefinitions&gt; &lt;ColumnDefinition Width="2*"/&gt; &lt;ColumnDefinition/&gt; &lt;/Grid.ColumnDefinitions&gt; &lt;Grid.RowDefinitions&gt; &lt;RowDefinition/&gt; &lt;/Grid.RowDefinitions&gt; &lt;dxg:GridControl Name="GridControlUser" ItemsSource="{Binding AlleICTSUser, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}" AutoExpandAllGroups="True" ShowBorder="True" Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="2"&gt; &lt;dxg:GridControl.View&gt; &lt;dxg:TableView Name="tableViewGrid" FocusedRow="{Binding SelecetetUser, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}" &gt; &lt;dxg:TableView.InputBindings&gt; &lt;KeyBinding Key="Del" Modifiers="Control" Command="{Binding RemoveICTSUserCommand}"/&gt; &lt;KeyBinding Key="N" Modifiers="Control" Command="{Binding AddICTSUserCommand}"/&gt; &lt;/dxg:TableView.InputBindings&gt; &lt;/dxg:TableView&gt; &lt;/dxg:GridControl.View&gt; &lt;dxg:GridControl.Columns&gt; &lt;dxg:GridColumn FieldName="Name" Header="Name"/&gt; &lt;dxg:GridColumn FieldName="Password" Header="Password" AllowEditing="{Binding SelecetetUser.CanEditPassword, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}"&gt; &lt;dxg:GridColumn.EditSettings&gt; &lt;dxe:PasswordBoxEditSettings IsEnabled="{Binding CanEditPassword}" /&gt; &lt;/dxg:GridColumn.EditSettings&gt; &lt;/dxg:GridColumn&gt; &lt;dxg:GridColumn FieldName="CanEditPassword" Header="CanEdit"&gt; &lt;dxg:GridColumn.EditSettings&gt; &lt;dxe:CheckEditSettings /&gt; &lt;/dxg:GridColumn.EditSettings&gt; &lt;/dxg:GridColumn&gt; &lt;dxg:GridColumn Header="Categorie" FieldName="SelectetProgrammCategorieIds"&gt; &lt;dxg:GridColumn.EditSettings&gt; &lt;dxe:ComboBoxEditSettings ItemsSource="{Binding AlleCategorien, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}" ValueMember="ID" DisplayMember="Name"&gt; &lt;dxe:ComboBoxEditSettings.StyleSettings&gt; &lt;dxe:CheckedComboBoxStyleSettings/&gt; &lt;/dxe:ComboBoxEditSettings.StyleSettings&gt; &lt;/dxe:ComboBoxEditSettings&gt; &lt;/dxg:GridColumn.EditSettings&gt; &lt;/dxg:GridColumn&gt; &lt;/dxg:GridControl.Columns&gt; &lt;/dxg:GridControl&gt; &lt;/Grid&gt; &lt;/dxlc:GroupBox&gt; </code></pre> <p></p> <p>Ok i Found a way but it isent the True thing it is a "littlebit" dirty i hope there is an other way. My target class must looks like this:</p> <pre><code> using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.ComponentModel; using Unattended_Tool.View.DataStore; using System.Collections.ObjectModel; using System.Xml.Serialization; namespace Unattended_Tool { public class ICTSPrinter : IDataErrorInfo { string _name; string _versionsname; string _location; ObservableCollection&lt;int&gt; _categorie; public ObservableCollection&lt;int&gt; Categorie { get { return _categorie; } set { _categorie = value; } } [XmlIgnore] public object SelectetProgrammCategorieIds { get { return (Object)Categorie; } set { Categories = new ObservableCollection&lt;int&gt;((value as IEnumerable&lt;Object&gt;).ToObservableCollection&lt;int&gt;()) { }; } public string Location { get { return _location; } set { _location = value; } } public string VersionsName { get { return _versionsname; } set { _versionsname = value; } } public string Name { get { return _name; } set { _name = value; } } public string Error { get; set; } public string this[string columnName] { get { Error = string.Empty; switch (columnName) { case "Name": if (string.IsNullOrEmpty(Name)) { Error = "Error"; } break; case "SelectetProgrammCategorieId": if (DataStoreSingelton.Instance.AlleCategories.FirstOrDefault(S =&gt; ((List&lt;int&gt;)SelectetProgrammCategorieIds).FirstOrDefault(s =&gt; s == S.ID) == S.ID) != null) { Error = "Please enter a vaild programm categorie"; } break; default: break; } return Error; } } } } </code></pre> <p>it Seems like DevExpress just accept an object in binding ... i could use an Converter but this would just an Workaround </p> <p>Im using the 12.1.5 version</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload