Subject | linker error in VS 2005 |
---|---|
Author | |
Post date | 2013-12-24T06:04:57Z |
I am building an application with the firebird 2.5 API. I keep getting
the following errors at compile time. I am using VS 2005 on win 7.
Error 1 error LNK2028: unresolved token (0A00004B) "extern "C" int __stdcall isc_print_status(int const *)" (?isc_print_status@@$$J14YGHPBH@Z) referenced in function __catch$??0Form1@CallSheet@@$$FQ$AAM@XZ$0 CallSheet.obj
Error 2 error LNK2028: unresolved token (0A00004C) "extern "C" int __stdcall isc_attach_database(int *,short,char const *,void * *,short,char const *)" (?isc_attach_database@@$$J224YGHPAHFPBDPAPAXF1@Z) referenced in function "public: __clrcall CallSheet::Form1::Form1(void)" (??0Form1@CallSheet@@$$FQ$AAM@XZ) CallSheet.obj
Error 3 error LNK2019: unresolved external symbol "extern "C" int __stdcall isc_print_status(int const *)" (?isc_print_status@@$$J14YGHPBH@Z) referenced in function __catch$??0Form1@CallSheet@@$$FQ$AAM@XZ$0 CallSheet.obj
Error 4 error LNK2019: unresolved external symbol "extern "C" int __stdcall isc_attach_database(int *,short,char const *,void * *,short,char const *)" (?isc_attach_database@@$$J224YGHPAHFPBDPAPAXF1@Z) referenced in function "public: __clrcall CallSheet::Form1::Form1(void)" (??0Form1@CallSheet@@$$FQ$AAM@XZ)
here is the code snippet where i get the errors:
#include <string>
#include <stdio.h>
#include <stdlib.h>
#include "ibase.h"
#include "ib_util.h"
#include "iberror.h"
***
db1 = initDBhandle(db1);
param_buffer = populate_dpb("SYSDBA", "masterkey");
db_pathname = "..\\CallSheet_DB\\CallSheet.fdb";
catch(exception e){
if (status_vector[0] == 1 && status_vector[1]){
/* An error occurred. */
isc_print_status (status_vector);
}
}
I have done extensive searching on the web for a solution to this. Near as I can tell, I am missing an library file of some sort with the actual functions in them.
Any help would be greatly appreciated. If you need more info please ask
Thanks
Error 1 error LNK2028: unresolved token (0A00004B) "extern "C" int __stdcall isc_print_status(int const *)" (?isc_print_status@@$$J14YGHPBH@Z) referenced in function __catch$??0Form1@CallSheet@@$$FQ$AAM@XZ$0 CallSheet.obj
Error 2 error LNK2028: unresolved token (0A00004C) "extern "C" int __stdcall isc_attach_database(int *,short,char const *,void * *,short,char const *)" (?isc_attach_database@@$$J224YGHPAHFPBDPAPAXF1@Z) referenced in function "public: __clrcall CallSheet::Form1::Form1(void)" (??0Form1@CallSheet@@$$FQ$AAM@XZ) CallSheet.obj
Error 3 error LNK2019: unresolved external symbol "extern "C" int __stdcall isc_print_status(int const *)" (?isc_print_status@@$$J14YGHPBH@Z) referenced in function __catch$??0Form1@CallSheet@@$$FQ$AAM@XZ$0 CallSheet.obj
Error 4 error LNK2019: unresolved external symbol "extern "C" int __stdcall isc_attach_database(int *,short,char const *,void * *,short,char const *)" (?isc_attach_database@@$$J224YGHPAHFPBDPAPAXF1@Z) referenced in function "public: __clrcall CallSheet::Form1::Form1(void)" (??0Form1@CallSheet@@$$FQ$AAM@XZ)
here is the code snippet where i get the errors:
#include <string>
#include <stdio.h>
#include <stdlib.h>
#include "ibase.h"
#include "ib_util.h"
#include "iberror.h"
***
db1 = initDBhandle(db1);
param_buffer = populate_dpb("SYSDBA", "masterkey");
db_pathname = "..\\CallSheet_DB\\CallSheet.fdb";
try{
isc_attach_database(status_vector,strlen(db_pathname.c_str()),db_pathname.c_str(),&db1,
dpb_length, param_buffer);
}
catch(exception e){
if (status_vector[0] == 1 && status_vector[1]){
/* An error occurred. */
isc_print_status (status_vector);
}
}
I have done extensive searching on the web for a solution to this. Near as I can tell, I am missing an library file of some sort with the actual functions in them.
Any help would be greatly appreciated. If you need more info please ask
Thanks