Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8534095
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T10:06:56+00:00 2026-06-11T10:06:56+00:00

First time question asked long time lurker. I’m working on a Silverlight app with

  • 0

First time question asked long time lurker.

I’m working on a Silverlight app with a view that implements a RadGridView. I have a ViewModel that binds a ObservableCollection of PersonSkills to that RadGridView. In the Model, PersonSkills is many to one Skill. Description is a property of Skill. They are joined by a foreign key on SkillId (Sorry not enough rep to post an image)

My column bindings in the RadGridView are to the Skill.Description property. Everything works fine until I make an edit in a dataform not represented here. The PersonSkills collection fires and I can see the changed value, and the change posts to the database but the RadGridView displays an empty cell instead of the Skill.Description like it should.

What do I need to do to get the RadGridView to reflect the changes that are made to a Property of the Skill collection which is a child of the PersonSkills collection?

   <telerik:RadGridView
        x:Name="skillsGrid"
        ItemsSource="{Binding PersonSkills, Mode=TwoWay}"
        SelectedItem="{Binding CurrentPersonSkill, Mode=TwoWay}"
        ColumnWidth="*">
        <telerik:RadGridView.Columns>
            <telerik:GridViewDataColumn
                Header="SKILL"
                DataMemberBinding="{Binding Skill.Description}"
                IsGroupable="False"
                Width="2*" />
        </telerik:RadGridView.Columns>
   </telerik:RadGridView>


private ObservableCollection<PersonSkill> personSkills;
    public ObservableCollection<PersonSkill> PersonSkills
    {
        get
        {
            return this.personSkills;
        }
        set
        {
            this.personSkills = value;
            this.OnUiThread(() =>
            {
                this.RaisePropertyChanged("PersonSkills","CurrentPersonSkill");
            });

        }
    }


private PersonSkill currentPersonSkill;
    public PersonSkill CurrentPersonSkill
    {
        get
        {
            return this.currentPersonSkill;
        }
        set
        {
            if (this.currentPersonSkill != value)
            {
                this.currentPersonSkill = value;
                this.RaisePropertyChanged("PersonSkills","CurrentPersonSkill");
            }

        }
    }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T10:06:57+00:00Added an answer on June 11, 2026 at 10:06 am

    I should have mentioned I was using a RadDatForm as well. It was the culprit. I gave up on using the RadDataForm. It was more trouble that it was worth. Instead I implemented a homegrown dataform through bound Commands in the viewmodel. Much cleaner IMHO. Hopefully it helps someone else out.

    <Grid
            x:Name="readOnlyForm"
            Visibility="{Binding RequestFormInEdit, Converter={StaticResource InvertedBooleantToVisibilityConverter}}">
            <StackPanel>
            <TextBlock
                Text="{Binding PersonSkill.Skill.Description}"/>
            </StackPanel>
            <StackPanel>
                <telerik:RadButton
                    Command="{Binding AddCommand}"
                    Tag="ADD">
                </telerik:RadButton>
                <telerik:RadButton
                    Command="{Binding EditCommand}"
                    Tag="EDIT">
                </telerik:RadButton>
            </StackPanel>
        </Grid>
        <Grid
            x:Name="editForm"
            Visibility="{Binding FormInEdit, Converter={StaticResource BooleantToVisibilityConverter}}">
            <Grid>
                <StackPanel>
                    <Grid>
                        <TextBlock
                            Text="SKILL"/>
                        <TextBox                                                                                                                Text="{Binding PersonSkill.Skill.Description, Mode=TwoWay}"/>
                    </Grid>
                </StackPanel>
                <StackPanel>
                    <telerik:RadButton
                        Tag="SAVE"
                        Command="{Binding SubmitCommand}">
                    </telerik:RadButton>
                    <telerik:RadButton
                        Tag="CANCEL"
                        Command="{Binding CancelCommand}">
                    </telerik:RadButton>
                </StackPanel>
            </Grid>
        </Grid>
    </Grid>
    

    And in my view model I’ve added the following

    private bool FormInEdit;
        public bool FormInEdit
        {
            get
            {
                return FormInEdit;
            }
            private set
            {
                if (FormInEdit != value)
                {
                    FormInEdit = value;
                    RaisePropertyChanged("FormInEdit");
                }
            }
        }
    
        private DelegateCommand addCommand;
        public DelegateCommand AddCommand
        {
            get
            {
                if (addCommand == null)
                {
                    addCommand = new DelegateCommand(
                       OnAddCommand);
                }
                return addCommand;
            }
        }
        private void OnAddCommand()
        {
    
            // create a new personskill code goes here
    
    
            // and begin edit
    
            FormBeginEdit();
    
        }
        private DelegateCommand editCommand;
        public DelegateCommand EditCommand
        {
            get
            {
                if (editCommand == null)
                {
                    editCommand = new DelegateCommand(
                        OnEditCommand);
                }
                return editCommand;
            }
        }
        private void OnEditCommand()
        {
           if (CurrentPersonSKill != null)
           {
                if (FormInEdit)
                {
    
                }
                else
                {
                    FormBeginEdit();
                }
            }
    
        }
    
        private DelegateCommand cancelCommand;
        public DelegateCommand CancelCommand
        {
            get
            {
                if (cancelCommand == null)
                {
                    cancelCommand = new DelegateCommand(
                        OnCancelCommand,
                                                                                                () => (CurrentPersonSkill != null) && FormInEdit);
                }
                return cancelCommand;
            }
        }
        private void OnCancelCommand()
        {
            if (CurrentPersonSkill != null)
            {
                FormCancelEdit();
            }
            FormEndEdit();
        }
    
        private DelegateCommand submitCommand;
        public DelegateCommand SubmitCommand
        {
            get
            {
                if (submitCommand == null)
                {
                    submitCommand = new DelegateCommand(
                        OnSubmitCommand,
                                                                                                () => (CurrentPersonSkill != null) && FormInEdit);
                }
                return submitCommand;
            }
        }
        private void OnSubmitCommand()
        {
                if (CurrentPersonSkill != null)
                {
                    //submit the PersonSkill here
                    FormEndEdit();
                }
        }
    
    
    
        private void FormBeginEdit()
        {
            if CurrentPersonSkill != null)
            {
                FormInEdit = true;
            }
        }
        private void FormEndEdit()
        {
            FormInEdit = false;
        }
        private void FormCancelEdit()
        {
            if CurrentPersonSkill != null)
            {
                FormInEdit = false;
            }
        }
    
        private void OnViewModelPropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e)
        {
            switch (e.PropertyName)
            {
                case "FormInEdit":
                    SubmitCommand.RaiseCanExecuteChanged();
                    CancelCommand.RaiseCanExecuteChanged();
                    break;
                case "CurrentPersonSkill":
                    SubmitCommand.RaiseCanExecuteChanged();
                    CancelCommand.RaiseCanExecuteChanged();
                    break;
            }
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know that this isn't the first time that this question has been asked,
I have asked this question twice i think, but this is the first time
this is my first time asking a question on stackoverflow. I'm working on a
this is my first time posting here, I have a question which I have
I'm working on a project in MVC 3 (first time using!). One question I
Sorry, this's my first time to ask a question here. So, I don't have
Long time lurker, first time asker. I am currently writing a custom theme for
This is the first time I've asked a question. It's the first time I've
this is my first time asking a question here. I tried to be well
this is my first time asking a question so bear with me. I am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.