Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linking a DOS pascal program with VC++ 1.52 program

Status
Not open for further replies.

oscillogoat

Programmer
Dec 20, 2004
7
0
0
US
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
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top