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 8867759
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T17:07:05+00:00 2026-06-14T17:07:05+00:00

I am developing wpf application. I have only one button in xaml page. On

  • 0

I am developing wpf application. I have only one button in xaml page. On click of it I have written the following code

private void button1_Click(object sender, RoutedEventArgs e)
        {

            PrintDialog printDialog = new PrintDialog();
            if (printDialog.ShowDialog() == true)
            {
                //PrintUsingDocumentCondensed("Hi", "Hello");
                printDialog.PrintVisual(button1, "Print123");
                //printDialog.PrintDocument("a",
            }
        }

I have attached printer to my system. When I click on print button in my application the printer start printing. The printer prints some text like BeginDefaults and EndDefaults, BeginResource and EndResource. Similary many other text. Also it print some text like ‘This job requires more memory than is available in this printer’, ‘For output format choose optimize for portability’, ‘Reduce number of fonts in documents’. etc
I think there is something going wrong with my printer. Or is there anything wrong with my code or application?. How should I print the actual button on print page with above code ? Can you please provide me any solution to the above link?

  • 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-06-14T17:07:06+00:00Added an answer on June 14, 2026 at 5:07 pm

    I checked to print text on notepad. It was giving the same error. Then I analysed that printer is not added properly. It was my mistake. Now added printer properly. Everything is now working fine

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am developing wpf application in C#. I have one button on which I
I am developing wpf application in C#. The following xaml code is working fine
I am developing wpf application. I have one static world map of 500 width
I am currently developing an application in C# using WPF, I have always only
I am developing a WPF application, and I need your advice. I have to
I am developing an application in C# WPF which will have Client-Server architecture (Client
I'm currently developing a WPF application in C# and I want to have a
I am developing an Application with the following layout, I have no knowledge of
I am developing a WPF application. I am basically a C++ developer and have
I am developing a WPF application, and have a TextBlock which I want to

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.