|
|
You can also use _access() as in:
if (_access("c:\\MyDir", 0) == 0)
;
else
;
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
|
Use FindFirstFile
jon
using System.Beer;
|
|
|
|
|
Hi,
I am using win32 API programming, I want to handle the selected windows in task manager, when we click minimize, maximise options for selected windows. How can I get the selected window(s) handle to send our user defined message.
I need to send some own message, before OS sending minimize/maximize message. Is it possible to get the handle please help me.
Thanks in Advance
|
|
|
|
|
Use FindWindow or FindWindowEx function in API. This will take window class and name as parameter, and will give you handle, if found. You can find window class using Spy++ utility, that comes with Visual Studio.
Arsalan Malik
|
|
|
|
|
try making a program that gets the window from point.
for example when you click somewhere on the screen the program would show you on a dialog box on some static text info about the window.
Use
WindowFromPoint()
gabby
|
|
|
|
|
Hi all,
Kindly clarify my doubt
I am developing the dialog based application in VC++.
I have created 10 buttons having captions like Bold, Italic, Underline, Right alignment, etc.
Some buttons can be enabled and some disabled.
My question is:
The tooltip is active ONLY for the enabled buttons.
I need to implement tooltip for the disabled buttons also
It will be great if anyone could help me
Thanks in Advance,
Chinna
|
|
|
|
|
In my dialog style mfc project, I've created a new generic class which is to handle some StaticText Controls. Passing CWnd from the CDialog, the generic class constructor creates the Static controls at run time (constructor call, .create(...)). It (seems) to work fine, since the text is displayed in the dialog. My Problem now is: How do I handle messages for the static text controls, e.g. mouse_move, mouse_down.
Help would be greatly appreciated
Sorry, if this is the wrong place for this, not sure if it belongs in managed c++
|
|
|
|
|
Ok my friend for getting any messages on any control you have to go through subclassing, by that you can get complete control over any control. See artical named "Windows Message Handling - Part 4" by "Daniel Kopitchinski" in "Dialog and Windows Programming topics" of CodeProject.
Hyperlink: http://www.codeproject.com/dialog/messagehandling4.asp
|
|
|
|
|
duh! sorry having wasted your time
duh! sorry having wasted your time
|
|
|
|
|
I saw ShellEx:
shellextguide3.asp[^]
shellextguide5.asp[^]
But I don't know How Can I overwrite existing General property page fields!?
I want to replace Gregorian Date with Persian Date that NOT supported in Windows XP or other windows!
|
|
|
|
|
I am currenlty going through a former colleague's code who used OVERLAPPED I/O to receive asynchronous serial data.
The program first declare a pointer variable pRxBuffer which will contain the received data. It then creates the port, then creates an overlapped event, and then reads the port which contains no data.
The program then waits indefinitely using WaitForMultipleObjects function. When the data arrives, the pointer variable pRxBuffer is immediately filled with the received data without using the ReadFile fucntion (or so it seems) and prior to calling the GerOverlappedResult function.
If this makes sense to someone, can you please explain to me how this is possible? How is the data transferred to pRxBuffer.
Thanks
|
|
|
|
|
That's how it works.
Basically, the initial ReadFile tells windows: here is a buffer, and here is the overlapped event is where I want you to tell me when you've filled the buffer.
There should also be a check on the return of ReadFile to check if the data has already arrived (which is possible).
Neil
|
|
|
|
|
Thank you.
It confirms my suspicions. I was however unable to detect it in the MSDN notes.
Cheers
|
|
|
|
|
Dear friends
I have to sort column in grid control and there are letters, numbers and
Japanese Text in the cell.
How about the algorithm and where I can get the solution way?
thanks a lot !
sincerely
joynet
share it, enjoy it.
|
|
|
|
|
Can anyone give me a pointer or two on how I go about writing a plugin for Internet Explorer. I can't seem to find anything on it on the web.
|
|
|
|
|
Search for "Browser Helper Object" or "BHO". You will find some examples here at codeproject.com as well.
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
|
That looks excellent many thanks.
|
|
|
|
|
where can i get tutorials on how to transfer an 8 bit wav file using parallel port in visual c++? thank a lot for the help guys. I really need it for our thesis project.. Thanks alot!!pls help me!
|
|
|
|
|
If you are using Win95 or Win98 then you may be able to do it using assembler. If you are using NT/2K or XP then things get more tricky.
Basically, you need a driver to allow direct access to the parallel port (which is not normally allowed).
I used one ages ago, which you could give a range of I/O addresses, and you could read or write to them via a DLL. I can't remember what it is called, but
Try googling for "parallel port access windows driver".
|
|
|
|
|
I've sucseffuly used a general purpose device drive called "TinyPort". It's good, but it warns you that it is relativly slow, being that it is general purpose, not specific to a device.
|
|
|
|
|
|
For interfacing with parallel or serial ports in VC6, you need to get a handle by calling CreateFile function. Pass "LPT1:" as filename.
Arsalan Malik
|
|
|
|