BGI error, How to Resolve it?

后端 未结 6 1782
独厮守ぢ
独厮守ぢ 2021-01-13 18:02

I want to run a C program that draws a circle. The program is compiling with no error and it is running. After getting the values like radius from the user, I get the error

6条回答
  •  礼貌的吻别
    2021-01-13 18:34

    I also suffered from that problem.

    Simply put this line:

    initgraph(&gdrive,&gmode, "c:\tc\bgi"); 
    

    here c:\tc\bgi is important.

    MOST IMPORTANT:

    In tc.exe (which you are using) at top are some menus like file, edit, options:

    • Go options>application
    • select overlay (By Default it is "standard" but you must select "overlay" option), then click on ok.
    • now you run your graphics progaram.

    NOTE: in the output, if it gives an error about bgi, ignore it, just give the input for the program if it is required and it will give you the graphics output. Enjoy.

提交回复
热议问题