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

Compatible PdfViewer height in WPF

1 Answer 41 Views
PDFViewer
This is a migrated thread and some comments may be shown as answers.
nandha
Top achievements
Rank 1
nandha asked on 13 Sep 2014, 08:28 AM
I used RadPdfViewer in WPF. I put the pdfviewer in grid. I set the height="*". But the problem is, the pdfviewer extends beyond the screensize of the window and the scrollviewer also not working. Help me to fix it. I have attcached the Snapshot of the window.

<Grid  >
       <Grid.RowDefinitions>
            <RowDefinition Height="*" />
        </Grid.RowDefinitions>
 <telerik:RadPdfViewer Grid.Row="0" x:Name="pdfViewer1"  DocumentSource="{Binding url1}"  telerikControls:StyleManager.Theme="Expression_Dark">
 </telerik:RadPdfViewer>
</Grid>

1 Answer, 1 is accepted

Sort by
0
Deyan
Telerik team
answered on 17 Sep 2014, 11:57 AM
Hello Nandhakumar,

If you use a single Grid in the Window it will be measured with the window size and the PdfViewer in row with height="*" should be measured in the same finite window height. In the other case when the mensioned Grid is inside some other element (for example Grid with row height="auto") then the inner grid may be measured with height Infinity and in this scenario PdfViewer will be measured with Infinity as well. This is the possible cause of the mensioned issue.

Could you please check whether in your scenario the Grid is nested in some other element measuring it in Infinity (Grid with row height "Auto", StackPanel, or some other content control)? 

I am looking forward to contacting you again.

Regards,
Deyan
the Telerik team
 
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
PDFViewer
Asked by
nandha
Top achievements
Rank 1
Answers by
Deyan
Telerik team
Share this question
or