Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 need a help on setting up borland c++
Index -> Programming, C++ -> C++ Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
myob




PostPosted: Tue Jan 25, 2005 9:17 am   Post subject: need a help on setting up borland c++

i am currently getting an error when im trying to run an easy file. it returns me an error which i included in the screenshot. ill also include the code too since that may help as wellk, i can ensure you that the code works. thanks in advance for anyone would help

Posted Image, might have been reduced in size. Click Image to view fullscreen.

code:
#include "ccc_win.h"

int main()
{
        double val1,val2,val3,val4,tempv,ulenx,uleny,len,initx,inity;
        string str1,str2,str3,str4;

   str1=cwin.get_string("Enter the first label: ");
   val1=cwin.get_double("Enter the first value: ");
        str2=cwin.get_string("Enter the second label: ");
   val2=cwin.get_double("Enter the second value: ");
   str3=cwin.get_string("Enter the third label: ");
   val3=cwin.get_double("Enter the third value: ");
   str4=cwin.get_string("Enter the fourth label: ");
   val4=cwin.get_double("Enter the fourth value: ");

   if (val1>val2) tempv=val1;
   else tempv=val2;
   if (tempv>val3);
   else tempv=val3;
   if (tempv>val4);
   else tempv=val4;
   ulenx=tempv/18, uleny=4, initx=-9.5, inity=-8;
   Point a(initx,inity), b(initx+val1/ulenx,inity), c(initx,inity+uleny);
   cwin << Line(a,b) << Line(a,c);
   a.move(val1/ulenx,uleny);
   cwin << Line(a,b) << Line(a,c);

   a.move(-val1/ulenx,0), b.move(-(val1/ulenx-val2/ulenx),uleny),
   c.move(0,uleny);
   cwin << Line(a,b) << Line(a,c);
   a.move(val2/ulenx,uleny);
   cwin << Line(a,b) << Line(a,c);

   a.move(-val2/ulenx,0), b.move(-(val2/ulenx-val3/ulenx),uleny),
   c.move(0,uleny);
   cwin << Line(a,b) << Line(a,c);
   a.move(val3/ulenx,uleny);
   cwin << Line(a,b) << Line(a,c);

   a.move(-val3/ulenx,0), b.move(-(val3/ulenx-val4/ulenx),uleny),
   c.move(0,uleny);
   cwin << Line(a,b) << Line(a,c);
   a.move(val4/ulenx,uleny);
   cwin << Line(a,b) << Line(a,c);

   cwin << Line(Point(initx,inity-1),Point(initx+tempv/ulenx,inity-1));
   Line d(Point(initx,inity-1), Point(initx,inity-1.5));
   for (int count=1; count<=7; count=count+1) cwin << d, d.move(3,0);
   len=0;
   for (int count=1; count<=7; count=count+1)
   cwin << Message(Point(-9.5+(count-1)*3,-9.5),len+(count-1)*ulenx*3);
   Point e(-8.5,-6.5), f(-8.5,-5.5);
   cwin << Message(e,val1) << Message(f,str1);
   e.move(0,4), f.move(0,4);
   cwin << Message(e,val2) << Message(f,str2);
   e.move(0,4), f.move(0,4);
   cwin << Message(e,val3) << Message(f,str3);
   e.move(0,4), f.move(0,4);
   cwin << Message(e,val4) << Message(f,str4) <<
   Message(Point(2,0),"Michael Cai");
   return 0;
}
Sponsor
Sponsor
Sponsor
sponsor
myob




PostPosted: Tue Jan 25, 2005 1:50 pm   Post subject: (No subject)

well, thx for looking, i got it fixed already.
Display posts from previous:   
   Index -> Programming, C++ -> C++ Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 2 Posts ]
Jump to:   


Style:  
Search: