How should i get the Paper type at runtime?
How should i get the Paper type at runtime?
If i set the paper type at runtime for all pages ? Then how should i get the paper type at runtime? (letter,A4,etc)
How should i get the Paper type at runtime?
Please examine Page.Height and Page.Width properties. These properties are represented in report's units (centimeters, inches).
Thank you.
Thank you.
How should i get the Paper type at runtime?
Only this is the way to get the type of paper ? Can i get directly type of paper ? means which paper type i have set in report ?
How should i get the Paper type at runtime?
For get type information you can use:
and later you can use for access to the page type
Also you can set page type by the following code, for example:
For access information about page type from designer you can use, for example:
Thank you.
Code: Select all
StiPage page = report.Pages[0];
Code: Select all
page.PaperSize.ToString()
Also you can set page type by the following code, for example:
Code: Select all
StiPage page = report.Pages[0];
page.PaperSize = System.Drawing.Printing.PaperKind.A5;
Code: Select all
{Page1.PaperSize}
How should i get the Paper type at runtime?
I have used same code in vb
Dim page As StiPage = Report.Pages(0)
But there is no property like
'page.papersize'
Is there any another way to get the paper type?
Dim page As StiPage = Report.Pages(0)
But there is no property like
'page.papersize'
Is there any another way to get the paper type?
How should i get the Paper type at runtime?
Please download the latest prerelease version of the StimulReport.Net. This property we've added in 2007.2 version.
Thank you.
Thank you.
How should i get the Paper type at runtime?
How should i download StimulReport 2007.2
How should i get the Paper type at runtime?
Please follow the link:
http://www.stimulsoft.com/DownloadsSR.aspx
Then you should select "StimulReport.Net 2007.07.12 D2005"
If you are registered user, then you should enter your registration data here:
http://www.stimulsoft.com/RegisteredUse ... ?login=yes
and then please follow the link:
http://www.stimulsoft.com/RegisteredUsers.aspx
Thank you.
http://www.stimulsoft.com/DownloadsSR.aspx
Then you should select "StimulReport.Net 2007.07.12 D2005"
If you are registered user, then you should enter your registration data here:
http://www.stimulsoft.com/RegisteredUse ... ?login=yes
and then please follow the link:
http://www.stimulsoft.com/RegisteredUsers.aspx
Thank you.
How should i get the Paper type at runtime?
Using form As Stimulsoft.Report.Render.StiPreviewForm = New Stimulsoft.Report.Render.StiPreviewForm(Report)
Dim stiPreview As Stimulsoft.Report.Render.StiPreviewControl = form.PreviewControl
Dim tb As StiToolBar = stiPreview.ToolBar
Dim btnSave As StiToolButton = TryCast(tb.Controls.Item("tbSave"), StiToolButton)
Dim btnExport As StiToolButton = TryCast(tb.Controls.Item("tbExport"), StiToolButton)
btnExport.Image = btnSave.Image
Report.Render()
Report.Compile()
form.ShowDialog()
Dim page As StiPage = Report.Pages(0)
MessageBox.Show(page.PaperSize.ToString)
End Using
I have used above code to to get the paper type at the time of closing the report if I set the page size to A4 or letter but still I get only custom type. How should i resove this problem?
Dim stiPreview As Stimulsoft.Report.Render.StiPreviewControl = form.PreviewControl
Dim tb As StiToolBar = stiPreview.ToolBar
Dim btnSave As StiToolButton = TryCast(tb.Controls.Item("tbSave"), StiToolButton)
Dim btnExport As StiToolButton = TryCast(tb.Controls.Item("tbExport"), StiToolButton)
btnExport.Image = btnSave.Image
Report.Render()
Report.Compile()
form.ShowDialog()
Dim page As StiPage = Report.Pages(0)
MessageBox.Show(page.PaperSize.ToString)
End Using
I have used above code to to get the paper type at the time of closing the report if I set the page size to A4 or letter but still I get only custom type. How should i resove this problem?
How should i get the Paper type at runtime?
You should reference a CompiledReport object instead of the Report object if you working with report after compilation.
Please modify your code in the following way:
If you modify a report template (Report template directly) with a new page size then you should call Compile method of the Report to apply changes.
Thank you.
Please modify your code in the following way:
Code: Select all
Dim page As StiPage = report.CompiledReport.Pages(0)
page.PaperSize = Printing.PaperKind.A5
MessageBox.Show(page.PaperSize.ToString)
Report.Render()
form.ShowDialog()
Thank you.