|
Hi there
I am currently working on a project in which i need to detect whether a file and/or folder is being deleted.
I have used CopyHook Handler but it asks whether to delete a folder or not.
I have used SHChangeNotifyRegister but it works only for files and not for folders.
Also it gives me multiple notificatioin for the same file.
Please if anybody has some solution then help me.
Its my "Semester Project " and the time is running out.
Your fellow programmer
modified 21-Apr-21 21:01pm.
|
|
|
|
|
FindFirstChangeNotification(....);
WaitForSingleObject(...);
FindNextChangeNotification(...);
FindCloseChangeNotification(...);
Use this in a thread(AfxBeginThread(...)) and post a message to your app when something changes.
|
|
|
|
|
I want to know how to play .wav file.I have downloaded a example here,but I don't understand the procedure on playing .wav file.a question that is the relation between the WaveFormatEx and HMMIO( the function of mmioOpen return value).can't the OS find the sound data automatically only by given WaveFormatEx in Memory?
|
|
|
|
|
You might be making this harder than it needs to be. Assuming you have the path to a wav file in variable, say szSoundFile
::PlaySound(szSoundFile, NULL, SND_FILENAME | SND_ASYNC | SND_NODEFAULT);
will play the sound for you. There's a whole bunch of options controlling how PlaySound works, relating to how currently playing sounds are handled and so on, but all the flags are documented in the platform SDK.
You'll need to #include "mmsystem.h", and link to winmm.lib, but that should do it for you.
|
|
|
|
|
the following is a bit of the code iam using! to access a database.
ConStr[0] = '\0';
strcat(ConStr, "SELECT * FROM prodlist WHERE product_name = 'aegis 1.0'");
pRecordset = m_pConnection->Execute(ConStr, vRecordsAffected, 1);
Now I want to assign it to another variable and then use the variable in place of 'aegis 1.0'.
to what variable should i assign it??
ranjani
|
|
|
|
|
CString strProductName;
CString strSelect;
strProductName = "aegis 1.0";
strSelect.Format("SELECT * from prodlist WHERE productname = '%s'", strProductName);
pRecordset = m_pConnection->Execute(strSelect, vRecordsAffected, 1);
Michael
|
|
|
|
|
my code doesn't recognize CString as a keyword.
do i have to include any spl header files for that??
ranjani
|
|
|
|
|
|
ok..what do i have to do now to solve my problem..??
kindly help me in this regard!
ranjani
|
|
|
|
|
thank u
have got a soln.
ranjani
|
|
|
|
|
How can I catch mouse click on ballon tooltip near the system tray icon?
|
|
|
|
|
1) Why doesn't \n work in CEdit controls, but \x0D\x0A has the right effect?
2) How to notify the compiler that you have ended the \x escape char? ("\x0D\x0AEllo world" will not be impreted as newline+"Ello world", but somehow as something where the first E will be a part of the second \x)
3) Programs like Alcohol 120% (advanced CD-ROM/-RW or DVD-ROM/-RW/+ROM/+RW etc. burning), have some controls that are not system standard, but have "TList" or something as template name. Where can I find them? (I have not yet tried to find them in the dependency files)
4) (Slightly offtopic)
A) What sound event is launched when WinXP shows it's fatal exception error dialog? (click here to see some tech info on the crash etc.)
B) How to set a set of sounds to one sound event, and each time te event is launched, one (random) of the sounds will be played?
5) How to make a static control which contains a hyperlink?
|
|
|
|
|
DaFrawg wrote:
3) Programs like Alcohol 120% (advanced CD-ROM/-RW or DVD-ROM/-RW/+ROM/+RW etc. burning), have some controls that are not system standard, but have "TList" or something as template name. Where can I find them? (I have not yet tried to find them in the dependency files)
These are custom window class controls. You won't be able to find them unless they are ActiveX controls. They are not part of the platform sdk or Windows common controls. TList maybe a Borland C++/Delphi control.
DaFrawg wrote:
4) (Slightly offtopic)
A) What sound event is launched when WinXP shows it's fatal exception error dialog? (click here to see some tech info on the crash etc.)
B) How to set a set of sounds to one sound event, and each time te event is launched, one (random) of the sounds will be played?
These are set in Control Panel under Sounds.
DaFrawg wrote:
5) How to make a static control which contains a hyperlink?
I use this http://www.codeproject.com/staticctrl/clabel.asp[^]
Michael
'Logic, my dear Zoe, merely enables one to be wrong with authority.' - The Doctor: The Wheel in Space
|
|
|
|
|
3) Hm. Okay. I guess they are not really more than the SysListCtrl32. Tnx.
4) I see, but what name? There is a list (I know, TreeCtrl) with a lot of names. Not that I don't know what to do, but what's the description of that (Program Exception/Hang) sound event?
5) Thanks. I reviewed the problem, and it always seems to be a Button.
|
|
|
|
|
DaFrawg wrote:
1) Why doesn't \n work in CEdit controls, but \x0D\x0A has the right effect?
have u tried giving a "\r\n" that's what \x0D\x0A corresponds to.
DaFrawg wrote:
2) How to notify the compiler that you have ended the \x escape char? ("\x0D\x0AEllo world" will not be impreted as newline+"Ello world", but somehow as something where the first E will be a part of the second \x)
maybe giving a space after the 2nd hex number. Or slit it into 2 string "\x0D\x0A" "Ello world"
My 2 cents.
|
|
|
|
|
1) (Smashes his own head a bit too hard against the wall, because he is using far-fetched tricks in stead of the simple soltion) Okay, thanks. But why does only '\r\n' work in stead of a single '\n'?
|
|
|
|
|
Have a problem compiling my VC++ 6.0 project in VC++ .NET
Compiler can't include <fstream.h>
Any clew??
APe
|
|
|
|
|
<fstream.h> was deprecated with the C++ standard of 1998, though many compilers has retained it for compatibility reasons.
Replace it with <fstream> , which is almost compatible, save the namespace issue. If you don't know what a namespace is, go find some info in any C++ tutorial. Meanwhile you can get by writing
using namespace std; right after all your #include s.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
OK,tanks but now another thing "happen".
Now I error for eg.
#include <math.h>
or
#include <math>
using namespace std;
??
APe
|
|
|
|
|
I am using Visual C++ 6.0 and my applications are targeted for all Windows platforms (well maybe not 95).
What do you advise? One of the MS COM object or one of the classes available here on CP?
Thanks to whoever takes the time to reply.
|
|
|
|
|
|
I deal with "simple" XML files, ie, no specific schemas etc.. so I also rolled my own parser and it saving and loading up of any XML file...
The MSXML object is awesome, but on startup requires like 16 Mb of member immediately... so its resource heavy...
www.kinkycode.com
[Glossary Manager] [AfterThought Backup Lite]
99 little bugs in the code, 99 little bugs,
Fix 1 bug, recompile....
101 little bugs in the code...
|
|
|
|
|
I also thought I could write my own parser, but then decided to use the CMarkup/CMarkupSTL[^] class.
Its cheap, it works and I got enough to do anyway.
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
I make pretty heavy use of XML, including schema's and suchlike. The library I use is Arabica (http://sourceforge.net/projects/arabica/[^]). Its a thin wrapper for MSXML,libxml and expat, the interface is pleasant to work with, unlike the underlying libraries.
Portable too.
Ryan.
|
|
|
|
|
Like someone posted earlier, try using CMarkup. I have a pretty simple XML settings file, which I read, and CMarkup works perfectly for my needs.
The kindest thing you can do for a stupid person, and for the gene pool, is to let him expire of his own dumb choices.
[Roger Wright on stupid people]
We're like private member functions
[John Theal on R&D]
We're figuring out the parent thing as we go though. Kinda like setting up Linux for the first time ya' know...
[Nitron]
|
|
|
|