This is a migrated thread and some comments may be shown as answers.

[Solved] RadHTMLPlaceHolder steals Focus

1 Answer 77 Views
HTMLPlaceHolder
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
asking
Top achievements
Rank 1
asking asked on 13 Sep 2011, 02:24 PM
Hello everybody,

I have a problem with the RadHTMLPlaceHolder and I hope that somebody can help me.

Scenario:
When a new source is assigned to it via (see the code below in XAML.cs):
this.RadHTMLPlaceHolder.HtmlPresenter.Children[0].SetProperty("src", htmlString);
...
after the source is assigned to the RadHTMLPlaceHolder the RadHTMLPlaceHolder
steals the Focus of my GridView, but I want the Focus to remain on the GridView-Control.

I've tried out following Events to control the Focus, but they didn't help:

        private void GridView_LostFocus(object sender, RoutedEventArgs e)
        {
            this.GridView.Focus();
        }

        private void RadHtmlPlaceHolder_UrlLoaded(object sender, EventArgs e)
        {
            this.GridView.Focus();
        }

Is there a property or an event or a command or a codesnippet with which I can
force the Focus to remain on my GridView when a Source is assigned to a RadHTMLPlaceHolder?

Please help me out!

Regards,
Asking Developer






1 Answer, 1 is accepted

Sort by
0
Petar Mladenov
Telerik team
answered on 16 Sep 2011, 03:05 PM
Hello Asking,

 Unfortunately, this cannot be achieved using the events of the RadHtmlPlaceholder. It could be achieved on a Button's click event which is fired after the HTML source is loaded. 

Greetings,
Petar Mladenov
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
HTMLPlaceHolder
Asked by
asking
Top achievements
Rank 1
Answers by
Petar Mladenov
Telerik team
Share this question
or