Telerik Forums
UI for WPF Forum
2 answers
133 views
Hello,

I am trying to use the Persistence Framework to persist a custom object, and am hoping to confirm some of the behaviour that I am seeing.

If I do not specify a custom property provider for my type, I observe the following:

  • Only properties that are primitive types get persisted.
  • However, nullable types are not supported.  You cannot return null for ProvideValue.
  • Properties that are complex types (i.e. other classes) do not get persisted.
  • Implementing ISerializable my classes (top-level or property classes) makes no difference!  (I.e. ISerializable.GetObjectData never gets called.)

 

If I do specify a custom property provider, I observe the following:

 

  • Only properties returned in GetCustomProperties get persisted.  This means, that I need to specify (and support) every property that I want persisted - even ones of primitive types.
  • For complex properties, I can create proxy objects to be saved.  But if these property types themselves have complex properties, it seems I need to package up the entire property tree in the proxy for my top-level property.  Is this true??!
  • Again, implementing ISerializable makes no difference as it never gets called.  This would be a nice way to serialize deep property structures as described in the previous point.

Since the persistence framework has a method that returns a Stream for a particular object, it surprises me that implementing ISerializable on the object I wish to persist does not help.  Am I missing something? 

Finally, if you cannot implement ISerializable, how do you go about persisting deep structures using the custom property provider? 

If someone could help clarify these observations, and perhaps offer a suggeestion about these deep property structures, that would be great!!

Thanks,
Mark

Mark
Top achievements
Rank 1
 answered on 23 Nov 2011
1 answer
105 views
Hello,

I was interresting by using RadRichTextBox with SpellChecking but I can't because SpellChecker 'underwaves' words seperated by simple quote in French :

"Ceci est un texte d'exemple écrit dans l'éditeur de texte enrichi."

In this sentence, the SpellChecker underwaves "d'exemple" and "l'éditeur" which are correct in French.

Is there a
fix planned?

Thanks,
Guillaume.
Iva Toteva
Telerik team
 answered on 23 Nov 2011
1 answer
172 views
I know this might sound like a strange request seeing as I'm using a docking control but...

Is there a way to prevent a user from moving a RadPane?

I have a particular RadPane I always want docked to a particular side of the screen.

I know people may argue it's bad UI design to restrict the users from moving it, but that's what my customer wants so that's the challenge I'm faced with.

I know I can prevent a panel from floating, closing a most of the other features but is there a way to stop a user from actually re-locating a panel to the other side of the screen?


Thanks,

CA.
George
Telerik team
 answered on 23 Nov 2011
3 answers
188 views
Hello,


I have a requirement wherein I want that the expanding image should always be visible irrespective of the child Item present or not.

I tried a lot but could not get how to do it.

A sample code would be helpful.

thanks and regards
Tina Stancheva
Telerik team
 answered on 23 Nov 2011
0 answers
130 views
Hi,

We are using Telerik WPF controls (ver. 2011.2.920.35) and we are trying to accomplish tooltips in the case of a validation failure in one of the grid cells.

Attached is a screenshot that highlights two cells - one with a combobox and the other with a text field. We want the validation errors to be presented for the cell with a combobox just like the way it gets presented for a text field column.

Please let us know how can we do that.

Any help is very much appreciated.

Regards,
Shalini L.
Shalini
Top achievements
Rank 1
 asked on 23 Nov 2011
0 answers
94 views
I am using RadDataFilter for search criteria. I want to get Where clause from Filterdescriptor, which will get record from database.
Currently when i get result from filter descriptor, it result like
"RequestCde isequalto 32"
I want result like
"RequestCde = 32"
Kamran
Top achievements
Rank 3
Iron
Iron
Veteran
 asked on 23 Nov 2011
1 answer
176 views
There are several things needed for help while using RadMenu in Toolbar control:
1. First of all, how to remove the border between the icon and header as shown on the attached file?
2. Under the situation of puting the menu with same submenu items included on the Dropdown button as dropdowncontent, and added to Toolbar, the problem is that the IsEnabled property of menuitem only works at the first time, but once the related data changed won't reflect to menuitems.   (The funcitonability of Command binded to the menuitem works as expected base on "CanExecut..." delegated command, but the UI of "IsEnabled" won't work. This means you can still clike the menuitem which return the "False" value from "CanExecut..." command.)  Any suggestion on this?

Regards,
Valeri Hristov
Telerik team
 answered on 23 Nov 2011
1 answer
139 views
Hi,

I need to hide dynamically a GridViewDataColumn in a hierarchical grid.

Dim column As GridViewDataColumn = Nothing
// _def is a GridViewTableDefinition added to my grid

                For Each column In _def.FieldDescriptors
                    If column.UniqueName.Equals(name) Then
                        column.IsVisible = false
                        Exit For
                    End If
                Next
           
My column is always visible. How can i do this ?
Thx


Pierrick
Top achievements
Rank 1
 answered on 23 Nov 2011
1 answer
185 views
Hi,

I have a custom edit appointment template which contains some controls that are made visible / collapsed based on certain selected criteria within the dialog. Unlike a normal window, the edit appointment dialog doesn't automatically resize while it's open. Is there a property or something that I can use to control this behaviour? Maybe changing the window style from a non resizeable toolbox window to one that is resizeable?

I am aware that I can use another 'factory' way of creating a custom appointment dialog as shown in the following post, but this means that I also have to implement a custom confirmation dialog, etc. and I would prefer not to have to do that.

http://blogs.telerik.com/blogs/posts/11-11-04/the-lob-chronicles-episode-13-extending-radscheduleview.aspx

Thanks!
Yana
Telerik team
 answered on 23 Nov 2011
1 answer
115 views
Hello, 

First, i precise that i'm french, so, sorry for mistakes you could find in this thread.

I'm working with a RadGridView, and, in witch column cells i have to place a Combobox.

I writed this code :

<Grid Width="900" >
        <Grid.RowDefinitions>
            <RowDefinition/>
            <RowDefinition/>
        </Grid.RowDefinitions>
        <telerik:RadGridView ItemsSource="{Binding ListIntervention}" IsSynchronizedWithCurrentItem="True" AutoGenerateColumns="False" ShowInsertRow="True" >
            <telerik:RadGridView.Columns>
                <telerik:GridViewComboBoxColumn Header="Objet intervention" Width="300"
                                                ItemsSource="{Binding ListObjet}"
                                                DataMemberBinding="{Binding ObjetId, Mode=TwoWay}"
                                                DisplayMemberPath="Libelle"
                                                SelectedValueMemberPath="Id"
                                                />
                <telerik:GridViewComboBoxColumn Header="Sous catégorie" Width="300"
                                                ItemsSource="{Binding ListSousCategorie}"
                                                DataMemberBinding="{Binding SsCategorieId, Mode=TwoWay}"
                                                DisplayMemberPath="Libelle"
                                                SelectedValueMemberPath="Id"
                                                />
                <telerik:GridViewComboBoxColumn Header="Catégorie" Width="*"
                                                ItemsSource="{Binding ListCategorie}"
                                                DataMemberBinding="{Binding CategorieId, Mode=TwoWay}"
                                                DisplayMemberPath="Libelle"
                                                SelectedValueMemberPath="Id"
                                                />
 
            </telerik:RadGridView.Columns>
        </telerik:RadGridView>
    </Grid>
 
And for the list, the definition is in a viewmodel class :
public class GestionAccueilViewModel : ActiveAwareViewModelBase
{
 
    #region Fields
 
    private readonly ITroncCommunService _troncCommunService;
    private readonly IMessageBoxService _messageBoxService;
 
    #endregion
 
    #region Ctor
 
    public GestionAccueilViewModel(ITroncCommunService troncCommunService, IMessageBoxService messageBoxService)
    {
        _troncCommunService=troncCommunService;
        _messageBoxService=messageBoxService;
 
        // Init.  
        ListSousCategorie=new ObservableCollection<TypeBouchonObjet>();
        ListCategorie=new ObservableCollection<TypeBouchonObjet>();
        ListObjet = new ObservableCollection<TypeBouchonObjet>();
        ListIntervention=new ObservableCollection<TypeBouchonIntervention>();
 
        // Mocks
 
        ListObjet.Add(new TypeBouchonObjet() { Id=1, Libelle="Date de paiement des prestations" });
        ListObjet.Add(new TypeBouchonObjet() { Id=2, Libelle="Autre objet" });
 
        ListSousCategorie.Add(new TypeBouchonObjet() { Id=1, Libelle="Logement nature" });
        ListSousCategorie.Add(new TypeBouchonObjet() { Id=2, Libelle="Autre sous-catégorie" });
 
        ListCategorie.Add(new TypeBouchonObjet() { Id=1, Libelle="AVNAT" });
        ListCategorie.Add(new TypeBouchonObjet() { Id=2, Libelle="Autre categorie" });
 
        ListIntervention.Add(new TypeBouchonIntervention() { ObjetId=1, CategorieId=1, SsCategorieId=1 });
        ListIntervention.Add(new TypeBouchonIntervention() { ObjetId=2, CategorieId=2, SsCategorieId=2 });
    }
 
    #endregion
 
    #region Listes
    private ObservableCollection<TypeBouchonIntervention> _listIntervention;
    public ObservableCollection<TypeBouchonIntervention> ListIntervention
    {
        get
        {
            return _listIntervention;
        }
        set
        {
            SetValueAndRaiseEventIfPropertyChanged<ObservableCollection<TypeBouchonIntervention>>("ListIntervention", ref _listIntervention, ref value);
        }
    }
 
    // Test RadGridView
    public ObservableCollection<TypeBouchonObjet> ListObjet { get; set; }
 
    public ObservableCollection<TypeBouchonObjet> ListCategorie { get; set; }
 
    public ObservableCollection<TypeBouchonObjet> ListSousCategorie { get; set; }
 
    #endregion
 
    #region Commands
 
    /// <summary>
    /// Valide l'accueil en cours
    /// </summary>
    public ICommand ValiderAccueilCommand
    { get; set; }
 
    /// <summary>
    /// RAZ de l'accueil en cours
    /// </summary>
    public ICommand AnnulerAccueilCommand
    { get; set; }
 
    /// <summary>
    /// Crée un nouvel écran d'accueil
    /// </summary>
    public ICommand NouvelAccueilCommand
    { get; set; }
 
    /// <summary>
    /// Recherche d'une personne via l'écran d'accueil
    /// </summary>
    public ICommand RechercherPersonneAccueilCommand
    { get; set; }
 
    #endregion

where TypeBouchon and TypeBouchonGrille are mocks class because, i'm just in the begin of development (any WCF Services implemented) :

public class TypeBouchon
    {
        public string Code { get; set; }
        public string Libelle{ get; set; }
    }
 
 public class TypeBouchonIntervention
    {
        public int ObjetId { get; set; }
 
        public int SsCategorieId { get; set; }
 
        public int CategorieId { get; set; }
    }

My problem :

I select a value in the comboxBox of the first column for example. When i focus the second combo (in the second column), the first column appears empty... 
I'd want to keep my selection in each columns...

I think my databing is correct, and i don't see the problem...

I send my screenshot in attach file.

Fab'
Dimitrina
Telerik team
 answered on 23 Nov 2011
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
SyntaxEditor
MultiColumnComboBox
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
DesktopAlert
WatermarkTextBox
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
VirtualKeyboard
HighlightTextBlock
Security
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?