Ticket Q508388
Visible to All Users

DocumentViewer not showing report unless i also have report.showpreview

created 12 years ago

Hi,

I have written a test application to show report data.

I would like to know what else I need to do to the following, because when I run the application the documentviewer1 control only (which is on a windows form of its own as i need to have other things on there) contains/shows report data if I include the newreport.showpreview line of code. This then means that I have two windows forms open with the report data.

I just want to show the documentviewer1 control on an existing form with the report data.
thereport is the xtrareport design.

_table = gdbmod.GetDataTable("select * from reports.report328vw")

_table.TableName = "report328dtl"

ds.Tables.Add(_table)

Dim newreport As New thereport

newreport.DataSource = ds

DocumentViewer1.DocumentSource = newreport

newreport.ShowPreview()

Comments (2)
DevExpress Support Team 12 years ago

    I am afraid I cannot find an appropriate solution to this problem without additional information. Would you please post here a small sample project that demonstrates this issue? This will make the situation clearer.

      Hi,
      Before assigning the report to the dcoumentViewer, you have the call newreport.CreateDocument(); No need of the newreport.ShowPreview().
      Hope this works
      Cheers
      Ravickumar M

      Answers approved by DevExpress Support

      created 12 years ago (modified 12 years ago)

      Hi,
      Before assigning the report to the dcoumentViewer, you have to call newreport.CreateDocument(); No need of the newreport.ShowPreview().
      Hope this works
      Cheers
      Ravickumar M

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.