hi every body!
I am trap in a problem regarding structure.
I have declare a structure as follow:
Code:
A.h
// this is the structure in which I have declare
typedef struct
{
static char name[0x100];
static char address[0x100];
static char employer[0x100];
}TExternalFilter;
AAAAAA(TExternalFilter* ExternalFilter);
//I have to pass the values of these members to a function whose prototype is:
A.cpp
AAAAAA(TExternalFilter* ExternalFilter)
{
char temp[256];
strcpy(temp,ExternalFilter->name);//so on
cout<<temp; //no output
}
main.cpp //from which values are send
TExternalFilter ExternalFilter={"aaaa","bbbb","ccccc"};
AAAAAA(&ExternalFilter);
//I am doing following but i am not able to fetch these values.
//Or in other words the values transfered are not visible in main program
//How can I do that
I want to clear that the structure declaration and function prototype can't be changed.There is no error in program.
I have to kept member as static.
What we can do is that we can only change the "main.cpp" program and no modification in A.h and A.cpp
Actually these two are DLL files and I have no permission to change DLL files only I change is main.cpp.
I am using VC++ 6.0 compiler.
Please keep this in mind and reply me soon.
Thanks
Bhagwat