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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T06:21:54+00:00 2026-05-15T06:21:54+00:00

I just started on the .net compact framework. I want to draw a Sudoku

  • 0

I just started on the .net compact framework. I want to draw a Sudoku field on the screen. So I put down a PictureBox and defined a method for the Paint event:

private void pictureBoxPlayfield_Paint(object sender, PaintEventArgs e)
{
    // use e.Graphics to draw the grid, numbers and cursor
}

This works, but you can see as the grid is drawn. So my question is, what is the right/better way to create such a custom control? Is there maybe a way to enable double buffering?

  • 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-15T06:21:54+00:00Added an answer on May 15, 2026 at 6:21 am

    There is no built-in support for double buffering in the Compact Framework. You can add it yourself, PictureBox already supports the Image property. Create a Bitmap in the constructor and assign it to Image. You don’t need the Paint event anymore, the one provided by PictureBox already draws it to the screen.

    Whenever the image needs to change, create a Graphics object with Graphics.FromImage(), passing the PB’s Image and draw your stuff. Call the PB’s Invalidate() method to tell it that it needs to redraw the image. If you still see flicker, override the PB’s OnPaintBackground() method and do nothing.

    The only other consideration is handling resizing, you’d need a larger or smaller Bitmap. Not so sure that would be necessary for a game.

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

Sidebar

Related Questions

i have just started playing aorund with asp.net mvc and i want to view
I just started to learn Android development. My previous experience is majorly .NET framework
I have just started with .NET Framework with C# as my language. I somewhat
I have just started with the .NET framework. Today, I was taught about the
I've just started programming in VB.Net and don't want to use Dreamweaver to do
Just started working with .NET and MVC(1). I'm having a problem wherein in my
I just started learning ASP.NET MVC4 today. After reading tutorials, downloading VS 2012, and
I've just started learning ASP.net and I can't seem to get the GridView to
Just started my first MVC 2.0 .net application. And I set up some default
Just started to get my feet wet with C# and .NET, liking it so

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.