Click here to Skip to main content
15,891,864 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
f1.h

C++
class A
{
   int i;
   char i2;
	
   struct strName
   {
      char b;
      int c;
   }
	
   union str1
   {
      int p;
      char t;
   }
	
   union str2
   {
      int p1;
      char t1;
   }
}

How to acess struct strName in another class named f2.cpp....?????
Posted
Updated 22-Oct-13 20:35pm
v4
Comments
Captain Price 23-Oct-13 3:09am    
A class cannot be named as f2.cpp. It is the file in which your class exists. So do you want to access A::strName from your f2.cpp file or from your "another class" ?
Darsana Ravi 25-Oct-13 3:18am    
i wanted to access A::strName from f1.h to f2.cpp

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900