不清不楚的
如果你用的是C语言,编译
程序代码:
#include <stdio.h>
#pragma comment( lib, "BAC.lib" )
_declspec(dllimport) void _stdcall P2T97 ( double P, double* T, int* Range );
_declspec(dllimport) void _stdcall P2HL97( double P, double* H, int* Range );
int main( void )
{
double p = 0.1;
double t; int trange;
double h; int hrange;
P2T97( p, &t, &trange );
P2T97( p, &h, &hrange );
printf( "%f, %d\n", t, trange );
printf( "%f, %d\n", h, hrange );
return 0;
}
若有错误,将错误信息贴出来
如果你用的是C++语言,编译
程序代码:
#include <cstdio>
#pragma comment( lib, "BAC.lib" )
extern "C" _declspec(dllimport) void _stdcall P2T97 ( double P, double& T, int& Range );
extern "C" _declspec(dllimport) void _stdcall P2HL97( double P, double& H, int& Range );
int main( void )
{
double p = 0.1;
double t; int trange;
double h; int hrange;
P2T97( p, t, trange );
P2T97( p, h, hrange );
printf( "%f, %d\n", t, trange );
printf( "%f, %d\n", h, hrange );
return 0;
}
若有错误,将错误信息贴出来