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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T23:36:04+00:00 2026-06-03T23:36:04+00:00

I’m writing a C++.NET 4.0 program that involves a form in Visual Studio 2010.

  • 0

I’m writing a C++.NET 4.0 program that involves a form in Visual Studio 2010. I’m adding a GraphicsPath to a Form. Here’s part of my code:

GraphicsPath^ gp=gcnew GraphicsPath();
gp->AddString("Hello world!", gcnew FontFamily("Arial"), (int) FontStyle::Italic, 26, (new PointF(100,100)), StringFormat::GenericDefault);

Compile and I get an error

 void System::Drawing::Drawing2D::GraphicsPath::AddString(System::String ^,System::Drawing::FontFamily ^,int,float,System::Drawing::PointF,System::Drawing::StringFormat ^)' : cannot convert parameter 5 from 'System::Drawing::PointF *' to 'System::Drawing::PointF'

So I change it to

 GraphicsPath^ gp=gcnew GraphicsPath();
gp->AddString("Hello world!", gcnew FontFamily("Arial"), (int) FontStyle::Italic, 26, *(new PointF(100,100)), StringFormat::GenericDefault);

and get more errors

1>LINK : error LNK2034: metadata inconsistent with COFF symbol table: symbol ‘??3@$$FYAXPAX@Z’ (060000A7) has inconsistent metadata
with (0A00001A) in MSVCURTD.lib(delete2.obj)
1>LINK : error LNK2034: metadata inconsistent with COFF symbol table: symbol ‘??3@$$FYAXPAX@Z’ (060000A7) has inconsistent metadata
with (0A000029) in MSVCURTD.lib(ti_inst.obj)
1>MSVCURTD.lib(delete2.obj) : error LNK2020: unresolved token (0A00001A) “void __cdecl operator delete(void *)” (??3@$$FYAXPAX@Z)
1>MSVCURTD.lib(ti_inst.obj) : error LNK2020: unresolved token
(0A000029) “void __cdecl operator delete(void *)” (??3@$$FYAXPAX@Z)
1>D:\Projects\SmartProjector\scratch\VS\Debug\CPPHelloWorld.exe : fatal error LNK1120: 2 unresolved externals

It should be simple, just convert the pointer to the PointF it actually points to but things get complicated for some reason I don’t know.

Could you tell me the correct way to use the System::Drawing::Drawing2D::GraphicsPath::AddString() function? Remember I’m using C++, not C#

  • 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-03T23:36:05+00:00Added an answer on June 3, 2026 at 11:36 pm

    Have you tried:

    gp->AddString("Hello world!", gcnew FontFamily("Arial"), (int) FontStyle::Italic, 26,  PointF(100,100), StringFormat::GenericDefault);
    

    this is at least the correct method signature

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

Sidebar

Related Questions

I am doing a simple coin flipping experiment for class that involves flipping a
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I've got a string that has curly quotes in it. I'd like to replace
I have this code to decode numeric html entities to the UTF8 equivalent character.
I have a French site that I want to parse, but am running into
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I have a text area in my form which accepts all possible characters from

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.