Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5932571
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T14:51:09+00:00 2026-05-22T14:51:09+00:00

In Windows Form application, it was as trivial as Creating a Form and bind

  • 0

In Windows Form application, it was as trivial as Creating a Form and bind the RPT file to the Form. Looks like this option isn’t possible with WPF.

I would like to show a Crystal Report on a new Window when a button is clicked. How to achieve this with WPF.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T14:51:10+00:00Added an answer on May 22, 2026 at 2:51 pm

    It can be done by using the Window Class:

    See code below for demonstration

    MyWindowType myReport = new MyWindowType(); // create a window, MyWindow is an User Control of type Window, that is it extends Window
    
    MyCrystalReport myReport = new MyCrystalReport();
    // Do necessary modifications to myReport such as Add Data and Send Parameters
    CrystalReportViewer rptViewer = new CrystalReportViewer(); // Construct a ReportViewer
    WindowsFormsHost host = new WindowsFormsHost(); // Create a WindowsFormsHost
    rptViewer.ReportSource = myReport; // Add Report to ReportSource 
    host.Child = rptViewer; // Add report viewer as child to host
    myReport.reportGrid.Children.Add(host); // Add host to MainWindow, that is myReport in this example
    myReport.BringIntoView();
    myReport.Show();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We are creating a Windows Form application (C# or VB.NET) that needs to reference
I have a C# Windows Form application that contains a menu with this event:
Im using c#.net windows form application. I have a xml file whose name is
I have this application (Windows form application written in Visual C++) from a colleague
I am building a Windows form application using .NET 3.5. I would like to
While creating a Windows Form Application, I selected target to .Net Framework 4.0. Now
Creating My Windows Form Application and using ADO.Net as Data Access layer and SQL
I am creating a Windows form application. I am using Devexpress 11.1. Is it
I have a windows form application that uses a Shared class to house all
I have a Windows Form application built on a data model and a Windows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.