oscillogoat
Programmer
I am trying to use a vc++ 1.52 program to call a DOS pascal program. MSDN says you can do this and gives the folowing
void __pascal maxparam(int __near * a, int __near * b);
main()
{
int a=5;
int b=7;
maxparam(&a,&b);
}
and the pascal...
MODULE Psub;
BEGIN
IF a> b then
b:=a
ELSE
a:=b
END;
END.
I am able to compile link and run a DOS pascal parent
calling Psub but when I try to link the C++ above with the pascal I get error 2029.. "unresolved external".
I have tried making Psub a library.
I am able to create a windows app when I link the pascal parent with psub in VC++.
How do I link the above C++ and pascal
void __pascal maxparam(int __near * a, int __near * b);
main()
{
int a=5;
int b=7;
maxparam(&a,&b);
}
and the pascal...
MODULE Psub;
BEGIN
IF a> b then
b:=a
ELSE
a:=b
END;
END.
I am able to compile link and run a DOS pascal parent
calling Psub but when I try to link the C++ above with the pascal I get error 2029.. "unresolved external".
I have tried making Psub a library.
I am able to create a windows app when I link the pascal parent with psub in VC++.
How do I link the above C++ and pascal