School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!
Welcome to Dream.In.Code
Become an Expert!

Join 340,155 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 3,992 people online right now. Registration is fast and FREE... Join Now!



graphics

graphics Rate Topic: ***-- 2 Votes

#1 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 09 April 2009 - 11:46 AM

Anybody answer me............. :
why am i having problems in using a headerfile for graphic initialization, what is an appropriate choice???
:blink:
Was This Post Helpful? 0
  • +
  • -


#2 chris772  Icon User is offline

  • D.I.C Head
  • PipPip
  • Group: Members
  • Posts: 169
  • Joined: 13-March 09


Dream Kudos: 0

Posted 09 April 2009 - 11:58 AM

1) Post your code
2) Post your header file's code (and name)
3) Tell us what your exact error/problem is
4) Ask for help in a way that lets us actually do something about your problem.
Was This Post Helpful? 0
  • +
  • -

#3 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 10 April 2009 - 11:16 PM

View Postchris772, on 9 Apr, 2009 - 11:58 AM, said:

1) Post your code
2) Post your header file's code (and name)
3) Tell us what your exact error/problem is
4) Ask for help in a way that lets us actually do something about your problem.



my compiler could not find the msoftcon.h
Was This Post Helpful? 0
  • +
  • -

#4 janotte  Icon User is offline

  • code > sword
  • Icon
  • Group: Expert w/DIC++
  • Posts: 2,675
  • Joined: 28-September 06


Dream Kudos: 0

Expert In: C/C++

Posted 11 April 2009 - 03:44 AM

View PostSyed Faraz, on 10 Apr, 2009 - 11:16 PM, said:

my compiler could not find the msoftcon.h


Unless you are prepared to provide us information we can't help you.

What compiler?
What is the exact error message.
Are you going to show us the code or what?

If you aren't going to help us help you expect very little response to your postings.
Was This Post Helpful? 0
  • +
  • -

#5 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 12 April 2009 - 11:31 PM

View Postjanotte, on 11 Apr, 2009 - 03:44 AM, said:

View PostSyed Faraz, on 10 Apr, 2009 - 11:16 PM, said:

my compiler could not find the msoftcon.h


Unless you are prepared to provide us information we can't help you.

What compiler?
What is the exact error message.
Are you going to show us the code or what?

If you aren't going to help us help you expect very little response to your postings.


There is a sample:

#include<constream.h>
#include<msoftcon.h>

struct circle
{
int xco, yco;
int rad;
color fillcolor;
fstyle fillstyle;
};

void circ_draw(circle c)
{
set_color(c.fillcolor);
set_fill_style(c.fillstyle);
draw_circle(c.xco, c.yco, c.rad);
}

int main()
{
init_graphics();
circle c1={15, 7, 5, cBLUE, X_FILL};
circle c2={41, 12, 7, cRED, O_FILL};
circle c3={65, 18, 4, cGREEN, MEDIUM_FILL};

circ_draw(c1);
circ_draw(c2);
circ_draw(c3);
set_cursor_pos(1, 25);
return 0;
}

my turboC++ compiler doesnt find the headerfile, using TurboC++ 3.0 by borland int.
Was This Post Helpful? 0
  • +
  • -

#6 janotte  Icon User is offline

  • code > sword
  • Icon
  • Group: Expert w/DIC++
  • Posts: 2,675
  • Joined: 28-September 06


Dream Kudos: 0

Expert In: C/C++

Posted 13 April 2009 - 12:13 AM

Please :code:
Was This Post Helpful? 0
  • +
  • -

#7 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 14 April 2009 - 09:19 PM

View Postjanotte, on 13 Apr, 2009 - 12:13 AM, said:

Please :code:

#include<constream.h>
#include<msoftcon.h>

struct circle
{
int xco, yco;
int rad;
color fillcolor;
fstyle fillstyle;
};

void circ_draw(circle c)
{
set_color(c.fillcolor);
set_fill_style(c.fillstyle);
draw_circle(c.xco, c.yco, c.rad);
}

int main()
{
init_graphics();
circle c1={15, 7, 5, cBLUE, X_FILL};
circle c2={41, 12, 7, cRED, O_FILL};
circle c3={65, 18, 4, cGREEN, MEDIUM_FILL};

circ_draw(c1);
circ_draw(c2);
circ_draw(c3);
set_cursor_pos(1, 25);
return 0;
}


sorry sir
Was This Post Helpful? 0
  • +
  • -

#8 janotte  Icon User is offline

  • code > sword
  • Icon
  • Group: Expert w/DIC++
  • Posts: 2,675
  • Joined: 28-September 06


Dream Kudos: 0

Expert In: C/C++

Posted 15 April 2009 - 03:18 AM

You may not have those files installed by default.

Have a read here about how to get them and use them.
http://www.tvdsb.on....s/msconsole.htm
Was This Post Helpful? 0
  • +
  • -

#9 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 20 April 2009 - 10:49 PM

View Postjanotte, on 15 Apr, 2009 - 03:18 AM, said:

You may not have those files installed by default.

Have a read here about how to get them and use them.
http://www.tvdsb.on....s/msconsole.htm


I'll check this out;
THANKS :)
Was This Post Helpful? 0
  • +
  • -

#10 Syed Faraz  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 8
  • Joined: 09-April 09


Dream Kudos: 0

Posted 24 April 2009 - 08:50 AM

View PostSyed Faraz, on 20 Apr, 2009 - 10:49 PM, said:

View Postjanotte, on 15 Apr, 2009 - 03:18 AM, said:

You may not have those files installed by default.

Have a read here about how to get them and use them.
http://www.tvdsb.on....s/msconsole.htm


I'll check this out;
THANKS :)

That again irritates me with 'windows.h'
hoping better :rolleyes:
Was This Post Helpful? 0
  • +
  • -

#11 prabh  Icon User is offline

  • D.I.C Regular
  • Icon
  • View blog
  • Group: Contributors
  • Posts: 294
  • Joined: 27-December 08


Dream Kudos: 25

Posted 24 April 2009 - 11:58 AM

View PostSyed Faraz, on 24 Apr, 2009 - 08:50 AM, said:

View PostSyed Faraz, on 20 Apr, 2009 - 10:49 PM, said:

View Postjanotte, on 15 Apr, 2009 - 03:18 AM, said:

You may not have those files installed by default.

Have a read here about how to get them and use them.
http://www.tvdsb.on....s/msconsole.htm


I'll check this out;
THANKS :)

That again irritates me with 'windows.h'
hoping better :rolleyes:

Dude if you are having same problem with this file search on internet and
modern compilers come with these files
use
check your include folder
and vc++ and other compilers also give this error because if you type
#include <windows.h>

so to clear this error
i type
#include <windows>






again if have the same problem then you need a new compiler

vc++ 2008list of free c++ compilers is here express is free
Was This Post Helpful? 0
  • +
  • -



Fast Reply

  

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month