S
Sandeep Chikkerur
Hi,
How do I call a function from one project to a function in another project?
e.g. In VC++ environment, if u've two different projects , say proj1 & proj2
/**************************** PROJ1 ************************************/
/******* main.c ***********/
#include <stdio.h>
#include "func_def.h"
void main()
{
fun();
}
/**************************/
/****** func_def.c ********/
void fun()
{
printf(".....");
}
/*************************/
/*************************** END OF PROJ1 ******************************/
If this project resides in : C:\Pro1
===========================================================================
Now project 2:
/******************************* PROJ2 ********************************/
/******* main2.c ***********/
#include <stdio.h>
#include "..\pro1\func_def.h"
void main()
{
fun();
}
/**************************/
/***************************** END OF PROJ2 ****************************/
If this project resides in say C:\Pro2
While pro2 is being linked it throws 'Unresolved external symbol _fun' error
How do I overcome this error & build the project successfully???
Thanking in advance...
~Sandeep
How do I call a function from one project to a function in another project?
e.g. In VC++ environment, if u've two different projects , say proj1 & proj2
/**************************** PROJ1 ************************************/
/******* main.c ***********/
#include <stdio.h>
#include "func_def.h"
void main()
{
fun();
}
/**************************/
/****** func_def.c ********/
void fun()
{
printf(".....");
}
/*************************/
/*************************** END OF PROJ1 ******************************/
If this project resides in : C:\Pro1
===========================================================================
Now project 2:
/******************************* PROJ2 ********************************/
/******* main2.c ***********/
#include <stdio.h>
#include "..\pro1\func_def.h"
void main()
{
fun();
}
/**************************/
/***************************** END OF PROJ2 ****************************/
If this project resides in say C:\Pro2
While pro2 is being linked it throws 'Unresolved external symbol _fun' error
How do I overcome this error & build the project successfully???
Thanking in advance...
~Sandeep