I want to hide a terminal appliction or console application without using WinAPI programming or <windows.h> or something like "ShowWindow(hwnd_win,SW_HIDE);
Taking a OS course and my professor gave us files to reference in a directory located at ~agw/class/os/share/proj3. But when I typed this into the terminal I keep getting a permission denied error message.
[lastname@erdos ~]$ ls dead.letter Desktop Documents Downloads Music Pictures private Public public_html Templates Videos [lastname@erdos ~]$ ~agw/class/os/share/proj3 /u/sobolev/agw/class/os/share/proj3: Permission denied. [lastname@erdos ~]$
I'm not sure what I am doing wrong. Ive opened shared directories for this class before and had no issues.
Taking a OS course and my professor gave us files to reference in a directory located at ~agw/class/os/share/proj3. But when I typed this into the terminal I keep getting a permission denied error message.
[lastname@erdos ~]$ ls dead.letter Desktop Documents Downloads Music Pictures private Public public_html Templates Videos [lastname@erdos ~]$ ~agw/class/os/share/proj3 /u/sobolev/agw/class/os/share/proj3: Permission denied. [lastname@erdos ~]$
I've opened shared directories for this class before and had no issues.
I've recently refreshed my mac by reinstalling the operating system. Uploaded the previous C and C ++ source scripts I was working with but when I go to compile them through the bash terminal it says command not found? Im not sure whats going because I thought that all the gcc files were already available? What am I messing here.
void generate_all_color_pairs(){ int foreground; int background; int i = 0; for(foreground=0; foreground<8; foreground++){ for(background=0; background<8; background++){ i++;
[code]....
but according on several sources, some terminals suport more colors.Is there any way to determine how many colors the current terminal supports?
I am using Xcode to do c++ programming and I have a c++ code, with different input arguments. I want to achieve that in Xcode, I could run multiple simultaneous running of my c++ code. However, the current problem is that once one code finishes, its terminal window automatically closed and I do not have time to look at its result. Thus computer time is wasted. Is there a way to run multiple same c++ code with different arguments input?
so i want to make a terminal for my website and BHXSpectre recommended cgi (which i love... c++ web design. just one more reason to not use any other language). anyways, im wondering how would i generate the html for the base of the terminal? ie just the window that i will be writing to
i am working on class project in which i have to save the tank from canon....imy tank is moving only when i press the moving key.. and after that i see blank screen what should i do to run my process when i am not pressing moving keys....
I have study that create a pipe and set a terminal of this pipe like a stdout of a process is a way to implement inter process comunication, but how can i do it in c++?
I wanted to make the terminal screen bigger in my NCurses program. Let's say if the defaults are 25 LINES and 80 COLS, I want to set them to 40 LINES and 120 COLS.
I've tried resizing all windows, but that did not work, because the actual terminal (console) was not resized. Then I found functions resizeterm and newterm, but they did not work. As far as my understanding goes resizeterm only updates NCurses information with the current configuration, while the window itself is not actually modified.
NCurses man page wrote:The function resizeterm resizes the standard and current windows to the specified dimensions
If I haven't made myself clear ( I sometimes make a mess of things... ), another example would be that I want my program to be fullscreen when I start it. Is this possible? It should be, I found a fullscreen NCurses program once, but the code was too confusing for me to understand.
Having read about things like SIGWINCH, I assume you must define a method for resizing the terminal screen yourself, I don't know where to start?
#include <stdio.h> main() { int c, n1; n1 = 0; while ((c = getchar()) != EOF) if (c == '') ++n1; printf("%d", n1); }
I have a more complicated program I'm wishing to have display the output, however, to save some time I'm using an example of a shorter version. count the lines in input and display the output in terminal when ./program is executed after compilation. To count and compute lines, words and within arrays.
I am trying to open a file and print the contents of the file to the terminal window. It works when I put the file right in the directory with the Solution but not if the file is out on my desktop and I use the full path. Here is the code:
#include <iostream> #include <fstream> #include <string> using namespace std; int OpenFile(){ fstream SampleFile;
I want to make a launcher for my program but the installation folder is different from one computer to another so I need a function or something that shows the path of the executable file.how to import a file from another folder.
#include<stdio.h> int main(void) { FILE *fp; *fp=fopen("C:Documents and Settings...something.txt","r"); }
I had wanted to make a program that will tell someone how many files there are in a folder and its subfolders with a certain extension. I am not sure how to find the files.
I am using dir object from dirent.h to read files of a folder. The code I am using in order to read all data is the following:
vector<string> directories;
DIR *pDIR; const char * c = path.c_str(); struct dirent *entry;
[Code]....
I am wandering when I am trying to read two times the files of the same folder, it will be stored with the same order or every time I ll read in folder it ll return different file order?
I want to rename all files in a folder (exactly I want to change extension file example:"FILE0001.CHK" to (FILE0001.JPG)), i know rename function , but how to use it all files, files names going sequencely (FILE0001.CHK,FILE002.CHK until FILE3000.CHK) ... How i can rename or change extension file quickly and easily.
im trying to write a file to a default document folder..something like...
FILE* file; file = fopen("%docdir% est.txt", "w"); fputs("Hello", file); fclose(file); "%docdir% est.txt" this isnt working for me, i have to write it as "C:userspublicdocument est.txt"
any method to write directly to default document folder so it will work in most Windows ? for example in windows 7 this is the default folder "C:users publicdocument est.txt" in windows XP its different
i have to detect the windows version first, to write the correct path
This question is currently only for windows; but I would like to know about a cross-platform way to perform what I want to do (explained below) -
I have created a little program:
#include <iostream> int main(int argc, char *argv[]) { for (int i = 0; i < argc; ++i) { std::cout << argv[i] << ' '; } }
I have added this program to the windows PATH. I put this program in C:Program FilesProgram
I now navigate to C:DataVariousTexts using CMD.
Then I type in: "program x"
The program will print out "program x" as by default. What I would like to get hold of is the folder in which the program is actually being called. ( I want to somehow get "C:DataVariousTexts" to be read into my program ).