I'm trying to convert some C programs into a dll in Visual c++. The subs will be called from a visual basic program. when the sub readfile is called I get the error R6002 Floating point not loaded. if I change the floats to int and change the data the dll works fine. Can anyone help me with this. I stripped the code down to barebones to make this post easier.
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
void _stdcall readfile(LPCSTR infile)
{
int line,column,ncol,nrow;
double nx,ny,ndat,ncell;
char row[6],col[6],x[10],y[10],cell[9],dat[13], char inputFilename[256];
FILE *ifp;
strcpy(inputFilename,infile);
ifp=fopen(inputFilename, "r"
/* Read input file */
fscanf(ifp,"%s%d%s%d%s%lf%s%lf%s%lf%s%lf",col,&ncol,row,&nrow,x,&nx,y,&ny,cell,&ncell,dat,&ndat);
}
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
void _stdcall readfile(LPCSTR infile)
{
int line,column,ncol,nrow;
double nx,ny,ndat,ncell;
char row[6],col[6],x[10],y[10],cell[9],dat[13], char inputFilename[256];
FILE *ifp;
strcpy(inputFilename,infile);
ifp=fopen(inputFilename, "r"
/* Read input file */
fscanf(ifp,"%s%d%s%d%s%lf%s%lf%s%lf%s%lf",col,&ncol,row,&nrow,x,&nx,y,&ny,cell,&ncell,dat,&ndat);
}