How can I invoke another program from within a C program?
Answers were Sorted based on User's Feedback
Answer / phani kumaer
just making the file name as preprocessor header file
and add this tag into the necessary program block
#include"Filename.h"
| Is This Answer Correct ? | 12 Yes | 2 No |
Answer / jai sundar
Just include tha other file name
#include "Filename.c" .
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / phani kumar s
by using the proprocessor directive notation.
convert ur program as .h file.
or
use the files with functions.
| Is This Answer Correct ? | 6 Yes | 4 No |
Answer / srinivas
Just use system() call
like
system(test.exe);
the above statement when executed will executes test.exe and
returns when test.exe finishes its executions./.
| Is This Answer Correct ? | 3 Yes | 3 No |
Answer / sharath
please can any one give an example program for this question
How can I invoke another program from within a C program?
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / vamshi
simply use
#include<file_name.exe>.
the file with appropriate extention.
| Is This Answer Correct ? | 1 Yes | 3 No |
Answer / phani kumar s
to access one C program in another C Program
there are two ways
1.making the file .exe and accessing and
2.include the file as the preprocess header
#include"File.h"
| Is This Answer Correct ? | 1 Yes | 3 No |
Answer / vrushali
I think the second solution works .. need to check....
| Is This Answer Correct ? | 0 Yes | 6 No |
What will the code below print when it is executed? int x = 3, y = 4; if (x = 4) y = 5; else y = 2; printf ("x=%d, y=%d ",x,y);
What does the c preprocessor do?
What is %d used for?
What is wrong with this initialization?
any restrictions have on the number of 'return' statements that may be present in a function. a) no restriction b) only 2 return statements c) only 1 return statements d) none of the above
A function can make the value of a variable available to another by a) declaring the variable as global variable b) Passing the variable as a parameter to the second function c) Either of the two methods in (A) and (B) d) binary stream
write a c prog for removing duplicate character from an array and sorting remaining elements using a single array
Hai what is the different types of versions and their differences
int main() { int days; printf("enter days you are late"); scanf("%d",days); if (days<=5) printf("5o paisa fine"); if (days<=10&&days>=6) printf("1rs fine"); if(days>10) printf("10 rs fine"); if(days=30) printf("membership cancelled"); return 0; } tell me whats wrong in this program? is it right?
Stimulate calculator using Switch-case-default statement for two numbers
What is wrong with this code?
what is the output of below pgm? void main() { int i=0; if(i) printf("pass"); else printf("fail"); }