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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T11:53:47+00:00 2026-05-12T11:53:47+00:00

previously, there is such method for Rectangle in MFC, i dont know why there

  • 0

previously, there is such method for Rectangle in MFC, i dont know why there is not for the c# version.

  • 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-12T11:53:47+00:00Added an answer on May 12, 2026 at 11:53 am

    Presumably it wasn’t deemed useful enough to merit inclusion.

    You could easily add it as an extension method if you want though (and if you’re using C# 3):

    public static Point Center(this Rectangle rect)
    {
        return new Point(rect.Left + rect.Width/2,
                         rect.Top + rect.Height / 2);
    }
    

    Note that as the values are expressed as integers, you could easily end up getting a non-exact value, assuming you want to return a Point rather than another structure using decimal or double.

    The above is actually for the System.Drawing.Rectangle struct. If you’re talking about a different Rectangle, please add the appropriate information and I’ll edit my answer.

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

Sidebar

Related Questions

I know there has been previous talk on here about screencasting tools/apps, however I
I am looking for such a method which allows me to add, remove DOM
In previous releases there were 3 ways to pass data from controller to view
There is previous little on the google on this subject other than people asking
How can I count how many previous FootNoteReference nodes there are in an xml
Is there a way to combine a previous translation when extracting the csv file
In previous versions of jQuery tabs there was an option to automatically set the
Is there a way to change the available elements based on a previous element
Continuing from my previous question , is there a comprehensive document that lists all
On a more abstract level then a previous question , in my experience there

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.