Home › Forums › C Programming › i got problem at system() function usage
- This topic has 2 replies, 3 voices, and was last updated 14 years, 11 months ago by
will.
Viewing 2 reply threads
- AuthorPosts
- February 9, 2006 at 8:21 pm #1931
manishsingh0007
ParticipantI am trying to use system function in my code but when i compile the code it comes out from program and displays a dialog box as”illigal operation”
12345678910111213#include<stdio.h><br />#include<stdlib.h><br />void main()<br />{<br />system("mkdir d:\naveen");<br />}<br />ex2:<br />#include<stdlib.h><br />#include<stdio.h><br />void main()<br />{<br />system("dir");<br />} - February 10, 2006 at 12:13 pm #3179
msaqib
ParticipantWel if you are using win 98 or win 95 then it should work fine. If you are using windows 2000 or XP then the code above will give the error.
Check to see if this function is returning -1, if yes then means this function have some errors while executing. - February 10, 2006 at 12:50 pm #3180
will
ParticipantIt’s because of the improved security in Windows XP or Windows 200. The functions like
- inp() [/*:1cuthl9v]
- utp()[/*:1cuthl9v]
- system();[/*:1cuthl9v]
does not work on an NT platform.
There may be some other problems, but I think using win 98 would resolve the problem.
- AuthorPosts
Viewing 2 reply threads
- You must be logged in to reply to this topic.