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

HTML control inside viewbox

3 Answers 67 Views
HTMLPlaceHolder
This is a migrated thread and some comments may be shown as answers.
Daniel
Top achievements
Rank 1
Daniel asked on 05 Apr 2011, 02:03 PM
Hello,

I have a control, with 3 columns. In the middle column I have a RadHtmlPlaceholder which fills the available space.
One requirement for this control is to work inside a viewbox.
My problem is that because the actual width and heigth of the HtmlPlaceholder are not changing when stretching the viewbox content, the HTML content has always the same size.

Is there a way to set the iframe width and heigth? (I know the scaling factor)

Thanks

3 Answers, 1 is accepted

Sort by
0
Petar Mladenov
Telerik team
answered on 07 Apr 2011, 11:23 AM
Hello Daniel,

Could you please send us your xaml so that we can get into your situation quickly? This way we could think up a workaround because there are some known issues of the RadHtmlPlaceholder related to resizing. On the other hand, do you actually need ViewBox? Are you going to use it only for the RadHtmlPlaceholder? Thank you in advance for your cooperation.


Greetings,
Petar Mladenov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Joshua
Top achievements
Rank 1
answered on 19 May 2014, 10:51 PM
Hello Telerik Support Team,

       Is there any resolution to fix the Scroll / Re-sizing issues for RadHtmlPlaceHolder inside a ViewBox ?
We used ViewBox on a parent page, so there is no way we can remove it at this point.  

FYI: When we tried RadHtmlPlaceHolder outside current project its working fine. But, issue is only when its inside a viewbox

Thanks for your help. 
0
Martin Ivanov
Telerik team
answered on 22 May 2014, 01:29 PM
Hi Joshua,

Keep in mind that the RadHtmlPlaceHolder control is not placed directly in the Silverlight plugin, which means that it is positioned above the plugin. When you place a html placeholder inside a ViewBox it won't be resized correctly. This is why instead of ViewBox I recommend you to use a Grid with columns and rows, this way the the placeholder will be resized properly. Another approach could be to handle the SizeChanged event of the viewbox and set the width and height of the placeholder inside the event handler. Here is an example code:
private void Viewbox_SizeChanged(object sender, SizeChangedEventArgs e)       
{  
    this.placeholder.Width = this.viewbox.ActualWidth;
    this.placeholder.Height = this.viewbox.ActualHeight;
}

Let me know if you have further questions.

Regards,
Martin
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
HTMLPlaceHolder
Asked by
Daniel
Top achievements
Rank 1
Answers by
Petar Mladenov
Telerik team
Joshua
Top achievements
Rank 1
Martin Ivanov
Telerik team
Share this question
or