d=ttl*drand48()-fit[0]; //intialize to reigon for first entry
The error I receive is one discussed on a number of different forums:
C:Documents and SettingssarabrownDesktopSarahScheduling Codestat.cpp|181|error: `drand48' undeclared (first use this function)|
C:Documents and SettingssarabrownDesktopSarahScheduling Codestat.cpp|181|error: (Each undeclared identifier is reported only once for each function it appears in.)|
||=== Build finished: 2 errors, 1 warnings ===|
It just seems to me theres a lot of conflicting information about if this is even possible to do on Windows and when I do try work around functions or calling double drand(void) I get a ton of errors. I'm hesitant to try rand() or something less precise. I was hoping maybe someone would be able to maybe suggest a compiler which will run this or a different library, right now I'm using Code Blocks IDE.
i am just making some new programmings and testing it. But every time after compile and run The dos window is closing and again I have to compile And run command so i want The dos windows should prompt me for next input rather than closing.
how can i minimize all open windows using c++ program? I want to call the minimize function at some places in my program... so write how the function structure can be made and how do i call it?
I have download the SOIL library [URL] for loading textures in OpenGL, however it doesn't come with a SOIL.lib file but a file called libSOIL.a and it says I need to compile it myself.
Basically I want to embed the QGIS canvas widget into a custom application. In order to do that, I need to build QGIS from it's source in order to obtain the devel *.lib, *.dll, *.h, etc. files required. To that result, I am trying to build either version 2.6.* or the current nightly build ~2.7 - 2.8 64 bit version. There is very little documentation on the x64 builds. Not to mention that CMake and I are not the best of friends.
My progress so far: - Successfully built the extremely out of date nightly build readme instructions of version 0.11 x86 - Partial success in creating CMake output to VS2010, but many required headers were not included such as gqsmapcanvas.h, (So even if I got it building I couldn't use the canvas widget in an application) *Note I updated the external packages to x64 versions, so it is not an architecture mismatch issue.
I have also had issues with QWT looking for QWT Polar header files, but I suspect this is another issue with the missing headers as most of the errors related to files contained in the original source from GIT.
i am doing a structure program "struct book",but at the time of run cmd is opening and i am getting 'windows don't send' error and program has been terminating.
the code is following:
#include<stdio.h> #include<conio.h> display(); struct book
I’m working on a project that has many pop up windows. They are not organized properly and things are getting messy. I’m wondering if there are any common practice or design patterns for solving this problem.
I’d like to give some concrete examples:
1. my program connects to two different tcp ports on the same ip. cutting off any of them, the user will be notified with a MessageBox. But in case of unplugging network cable, both message box will show, which is unnecessary.
2. we provide a shortcut key to display a setting dialog. However the program can also show the same dialog when certain event happens. If the user opens the setting dialog already, those event will still trigger a second setting dialog.
3. when application settings are not correct, user will disconnect from the server and an error dialog will show up and terminate the program. But if the user knows about the situation and has opened the setting dialog to fix the issue, the error dialog will terminate his work. which is bad.
I don’t know how to deal with this window management problem in a complex software project. Of course, I can solve the issue case by case by checking if certain dialog is shown before displaying another dialog. But there are too many cases, when the code base gets big, this is not practical. There must be some generic solution I think.
I've just integrated the Windows SDK V7.0A into my VS2005 application, and I'm getting the dreaded "Application configuration error" when I try to run it on an XP machine.
It runs fine on the development machine, and some customer machines (Win7 and Win8), but will not run on XP due to missing/incorrect version dlls.
I've rebuilt all my libraries, but still no joy.
So, my first question is - If I upgrade the Windows SDK to V7.0A, do I also need to use MFC 10 and msvcrt10, or can I stick with MFC 8?
The next question is, how do I find out which dlls are missing, and which libraries or other dlls are requesting the missing versions?
In my application I have some type of windows showed in an instance of time, and an action shows a new one that i want have the focus all the time , in the way that i can't works with no one of the others. They all are windows, child windows an modeless dialogs, but i don't know how to do. I try use EnableWindow(FALSE) that all the others windows and dialogs, but not works.
I would like to be able to safely eject a USB drive (in Windows) when user selects that drive in a listbox and clicks the Eject button in an MFC dialog app. Any functions or (link) that would be up to date (i.e. compatible with Windows 8)?
I don't use Visual Studio and/or C++ so I would like to do it without them. I found this article c++ - How to determine CPU and memory consumption from inside a process? - Stack Overflow
I tried some lines of code but no one works for me.
I'm fairly new to visual C++ programming in a windows form and the code displayed below works fine. However my issue is as soon as the program is running it will display "failure" on label7 as soon as the button is clicked. I understand why it is doing this as "a" is not in the textbox at this time so it reads the else line and displays the message. When I enter "a" in the textbox everything works fine and label7 changes to the right message.
trying to convert some C++ code written for LINUX/MAC to run on windows. I think signal handling is not as developed for Windows but the error I am getting is that the struct I am trying to use is undefined. I have #include <csignal> at the top and the line giving the problem simply says "struct signal act;". Any pointers or is signal a LINUX native command?
I have developed the msword automation using the following link
[URL] ....
and using VC++ in Visual studio 2010,and msoffice 2007.
Its working fine. but the exe can not run in windows xp (same msoffice 2007 and installation folder also same). i do not know what is the problem. plz tell about how compactability in both os and different version of office like 2003, 2007, 2010, etc....
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 ).
i am trying to create a program for multiple windows. Here is my code
#include<Windows.h> // Store handles to the main window and application instance globally. HWND ghFirstWnd =0; HWND ghSecondWnd=0; HWND ghThirdWnd=0; HINSTANCE ghAppInst=0;
[Code]...
problem is when i try to execute the code it just say create window1- failed!!
I'm creating a simple game with my friend that runs in the Terminal/Command Prompt window, but I would like to know how to change the color of the entire window via C++. I'm on a Mac, but my friend is on a Windows, so I need to a solution that is portable, if possible.
I've tried using a printf statement to change the color, but it only changes the background color of the text being printed.
With the LoadLibrary function (followed by GetProcAddress) you can get a function or any other thing that is on DLL export. AFAIK, when you assemble one program, it loses all user-reading data (names in general). How do the OS's get them?