开发者

How get page size from MemoryStream or Byte?

开发者 https://www.devze.com 2022-12-29 10:48 出处:网络
I have images of active report in database, when i get into bytes and convert into memory stream so it can pass to active report viewer then how i get paper size of paper display in active report?

I have images of active report in database, when i get into bytes and convert into memory stream so it can pass to active report viewer then how i get paper size of paper display in active report? My code :

 Dim repmem As New System.IO.MemoryStream(rptBytes)
 repmem.Position = 0
 Viewer1.Document.Lo开发者_运维百科ad(repmem)


Every document page has its own size which could be accessed as:document.Pages(0).Size


See the Page.Width property in the ActiveReports Online Help. Your code will be something like:

 Dim repmem As New System.IO.MemoryStream(rptBytes)
 repmem.Position = 0
 Viewer1.Document.Load(repmem)
 Dim pageWidth as Single
 pageWidth = Viewer1.Document.Pages(0).Width
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号