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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T09:36:00+00:00 2026-06-08T09:36:00+00:00

doing some C++/CLI coding again, and running into issues. Working in VS2008 if it

  • 0

doing some C++/CLI coding again, and running into issues. Working in VS2008 if it matters at all.

Here’s a mock up of what I am trying to do. In reality ClassA is the GUI and ClassB is the backend that the gui needs to interact with. I am trying to give them access to eachother by passing them to eachother, but I cannot properly get them in scope to create a reference to the other one.

http://pastie.org/private/tnyxazwtyzv3luddz7seq

If you have any input I would greatly appreciate it. I have spent much of today looking online and this solution I currently have has gotten me quite close but I am still getting compile errors. Here’s what I am now getting:

Error   1   error C2653: 'NameSpaceB' : is not a class or namespace name    c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\A.h 12  myhello
Error   2   error C2143: syntax error : missing ';' before '^'  c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\A.h 12  myhello
Error   3   error C4430: missing type specifier - int assumed. Note: C++ does not support default-int   c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\A.h 12  myhello
Error   4   error C4430: missing type specifier - int assumed. Note: C++ does not support default-int   c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\A.h 12  myhello
Error   5   error C2653: 'NameSpaceA' : is not a class or namespace name    c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\B.h 12  myhello
Error   6   error C2143: syntax error : missing ';' before '^'  c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\B.h 12  myhello
Error   7   error C4430: missing type specifier - int assumed. Note: C++ does not support default-int   c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\B.h 12  myhello
Error   8   error C4430: missing type specifier - int assumed. Note: C++ does not support default-int   c:\users\andy\documents\visual studio 2008\projects\myhello\myhello\B.h 12  myhello

This is the same error I am getting in my actual project, so I know it’s something funky with my configuration.

  • 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-08T09:36:04+00:00Added an answer on June 8, 2026 at 9:36 am
    /*B.h File Contents*/
    #ifndef CLASSB_H
    #define CLASSB_H
    #include "A.h"
    

    Remove the #include "A.h" part and you’re golden. Since class B doesn’t use A (at least in the definition), there’s no need for the include.

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

Sidebar

Related Questions

Doing some homework here (second assignment, still extremely green...). The object is to read
Doing some R&D for my company. We are trying to have a listView that
I am new to Amazon Services and facing some issues. Suppose I am running
I have some long-running CLI PHP scripts that run regularly via cron. I'd like
Firstly, I'm some what new to C++/CLI . After doing some research I've found
Doing some jquery animation. I have certain divs set up with an attribute of
In doing some bioinformatics work, I've been pondering the ramifications of storing object instances
After doing some Core animations using: [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:0.5]; [self setAffineTransform:CGAffineTransformIdentity]; [UIView
While doing some JavaScript performance tests I came up with the following piece of
While doing some random experimentation with a factorial program in C, Python and Scheme.

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.