PDA

View Full Version : How To Open a text file



Numan Ali
02-27-2018, 10:24 AM
Hi Every One!
I am trying to open a text file from OpenGL but does not open. Kindly help me in this problem. The following are the codes which I am using for opening a text file from OpenGL.

case 'o':
glPushMatrix();

FILE* file = fopen("E:\\Files\aa.txt", "r+")

glPopMatrix();

:(

mhagain
02-27-2018, 11:47 AM
OpenGL has absolutely nothing to do with file IO.

Your question makes no sense. What are you actually trying to do?

Numan Ali
02-28-2018, 09:17 AM
I am trying to open a text file or other exe file from OpenGL code and the file opening should be opened by pressing "case button" in OpenGL which I have send the code in the above example.