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

  • SEARCH
  • Home
  • 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 4024066
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T10:40:32+00:00 2026-05-20T10:40:32+00:00

I must create application, where it can be to load some image, apply some

  • 0

I must create application, where it can be to load some image, apply some filters, draw few lines and save it. And I must do it using WPF. How I can draw on Image control in WPF? Or another control is better for it?

  • 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-20T10:40:33+00:00Added an answer on May 20, 2026 at 10:40 am

    You can do this by adding InkCanvas to your page, add your image as Background Image of InkCanvas, and add save functionality.

    1. Add InkCanvas to your WPF Form:
      1. Open the Toolbox (on the View menu, click Toolbox)
      2. Right-click the Toolbox, and then click Choose Items (Choose Toolbox Items dialog box opens)
      3. On the WPF Components tab of the Choose Toolbox Items dialog box, scroll down to InkCanvas and select it so that a check appears in the check box.
      4. Click OK to add the InkCanvas control to the Toolbox.
      5. Drag an InkCanvas control from the Toolbox to the design surface.
    2. Add your image as a background of InkCanvas. You can do it either in properties window under Background or in XAML
    3. Add “Save” button to your form and use following code to save it:

      string newImagePath = "your file path";
      var ms = new MemoryStream();             
      
      using (FileStream fs = new FileStream(newImagePath , FileMode.Create)
      {
          var rtb = new RenderTargetBitmap((int)inkImageCanvas.Width, (int)inkImageCanvas.Height, 96d, 96d, PixelFormats.Default);             
          rtb.Render(inkImageCanvas);             
          JpegBitmapEncoder encoder = new JpegBitmapEncoder();             
          encoder.Frames.Add(BitmapFrame.Create(rtb));              
          encoder.Save(fs);             
      }
      

    newImagePath is the path to new file; inkImageCanvas is your InkCanvas control.

    This will save content of your inkCanval to jpg file.

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

Sidebar

Related Questions

How can I create an application that performs an action with keyboard shortcut (App
I create a .NET (WPF) Application, and compile it to .EXE. Then I create
I am working on an ASP.Net web application that must print dynamically created labels
I have to create a site definition for a client that must contain pre-defined
Would the following SQL statement automatically create an index on Table1.Table1Column, or must one
What's the proper way to create a hyperlink in Spring+JSP? There must be a
In Silverlight, when you want to create a control dynamically, you must add the
There must be a generic way to transform some hierachical XML such as: <element1
I must be getting daft, but I can't seem to find how to read
Greetings, I'm working on a JS-based application that does some complex work and logs

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.