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

Scroller Bar position

1 Answer 47 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.
Dave
Top achievements
Rank 1
Dave asked on 19 Jan 2012, 08:35 AM
I have seen an example of getting and setting the position of the ScrollViewer control.  How do we Get and Set the position of each ScrollViewer bar within the RadHtmlPlaceHolder?  Any guidance is appreciated.
Cheers,

1 Answer, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 23 Jan 2012, 03:11 PM
Hello Dave,

The RadHtmlPlaceholder places its content in a div (if the RadHtmlPlaceholder.HtmlSource is set) or in an IFrame (if the RadHtmlPlaceholder.SourceUrl is set) on the html/aspx page hosting the Silverlight plug-in. This is why you can control the scroll bars in the RadHtmlPlaceholder either by setting the overflow properties applied to the html/aspx page elements or by controlling the IFrame scrolling attribute.

Basically when you display an external page in the RadHtmlPlaceholder, you can access the content of the IFrame object like so:
HtmlElement iframe = (HtmlElement)myHtmlPlaceHolder.HtmlPresenter.Children[0];
HtmlWindow contentWindow = iframe.GetProperty("contentWindow") as HtmlWindow;
HtmlDocument document = contentWindow.GetProperty("document") as HtmlDocument;

I hope this information will help you.

Regards,
Tina Stancheva
the Telerik team

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

Tags
HTMLPlaceHolder
Asked by
Dave
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Share this question
or