I would like to know if there are any ways to programmatically detect or monitor the file or folder being copied either by copy command(like on command prompt-- copy a b) or by using drag/drop(ctrl+c and ctr+v).
It would be helpful if you could give some pointers( preferably some APIs in vc++)
I want to build an application with publish/subscribe model for UDP communication for a real time simulation system. I'm new to this communication model and need to know much about the publish/subscribe model. We are using the Client/Server model for the communication. Where can I get some details about this model and what is the middleware I should be using.
GetOpenFileName() is Win32 API function which accepts a pointer to a OPENFILENAME structure. In this structure, you have to set up a member lStructSize to sizeof(OPENFILENAME) for Windows XP and above. But for Windows98 it must be OPENFILENAME_SIZE_VERSION_400. When I use an if statement to do it, compiler gives fatal error and stops :
ofn.lStructSize = sizeof(OPENFILENAME); //for Windows XPelse
ofn.lStructSize = OPENFILENAME_SIZE_VERSION_400; //for Windows 98/ME
Ofcourse I can make seperate functions for opening files in win98 etc. But what is a better way to do this.
I am trying to sort a list using the insertion sort algo, but my application crashes. I think those pointers lost track by using the remove function. Is there a better way to sort except using the sort() (list.sort() function). It does not work too well with it since I am sorting by Departure Time of the object in the list.
Here is the code i wrote:
//Insertion sort to sort runs by departure time in the Res_RunList
int numruns = Res_RunList.size(); //the size of the list
ListOfRuns::iterator Tempitr1; //create itr poniters to navigate thru the list
std::list <RDLRun*> TempList;
Tempitr1 = Res_RunList.begin(); //points to the 1st element
Tempitr2 = Res_RunList.begin();
Tempitr6 = Res_RunList.begin();
for(int low = 1; low < numruns; ++low)
++Tempitr2; //points to low position
RDLRun *TempRun = (*Tempitr2); // store the data from low position in TempRun
int u = low -1;
Tempitr3 = Tempitr2;
Tempitr4 = Tempitr3--; //ponits to u position
//compare the time windows
while(u >=0 && ( (*Tempitr4)->GetDepartureTime() > TempRun->GetDepartureTime() ) )
Tempitr5 = Tempitr4;
Res_RunList.remove((*Tempitr5++));//to prevent duplicate
}//end while loop
bool operator() (RDLRun* a, RDLRun* b) const
if( a->GetDepartureTime() < b->GetDepartureTime() )
else return 0;
Compiler error message:
--------------------Configuration: fstool - Win32 Debug--------------------
c:\program files\ilps\code\fstool\tempres.cpp(837) : fatal error C1001: INTERNAL COMPILER ERROR
(compiler file 'msc1.cpp', line 1786)
Please choose the Technical Support command on the Visual C++
Help menu, or open the Technical Support help file for more information
Error executing cl.exe.
i use ado to get data from database in vc, but now i want to let the data displayed in ms-word ,and then i can print
i just want to use word, no crystal report
pls give me some suggestions or materials
or complete steps to let data displayed in ms-word
i need help
thanks a lot
1) Write the data to the printer (driver) using code.
2) Write the data to a text file, and use ShellExecute(hWnd, "print", "data.txt", ...) on that text file. This will default to Notepad, but you can specify Winword.exe instead.
3) Use Word Automation.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
If only code inside function body of the dll file was changed (no functions were added or deleted and function signitures were not changed), but exe itself was not re-compiled, may the dll cause any dangrous (or problem) for the exe file?
the Q related to software auto-updates.
For lite reason, I don't want to update exe when update dll.
It is safe to change the internal implementation of the exported functions, as long as you retain the signature. It is also perfectly safe to add more new functions, but you should not remove an existing function that may be used by the executable.
hello, i am having a problem with this code. I do not know what is wrong. I enter the begbal, the ourdep and the withdraw. But in the end when goes to get the final balance. The answer is always the same as the input of begin bal. Any help would be greatful.
#define SENTINEL 0
int main (void)
printf("BANK RECONCILIATION FOR: 10/21/98");
printf("\n\nEnding balance on statement:");
scanf ("%f", & endbal);
printf("Enter Outstanding dep (or %d to quit)>", SENTINEL);
scanf ("%d", & outdep);
while (outdep!= SENTINEL)
finbal = finbal + outdep;
printf("Enter outstanding dep (%d to quit)>", SENTINEL);
scanf("%f", & outdep);
printf("Outstanding check/withdrawal (or %d to quit)>", SENTINEL);
scanf ("%d", & withdraw);
finbal = finbal - withdraw;
printf("Enter withdrawal (%d to quit)>", SENTINEL);
scanf("%f", & withdraw);
finbal = endbal + outdep - withdraw;
printf("Your final balance in your checkbook should be $ %f" , finbal);
Last Visit: 31-Dec-99 18:00 Last Update: 27-Sep-23 6:35