Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2004.03.28;
Скачать: CL | DM;

Вниз

Как на время работы программы заблокировать автозапуск CD?   Найти похожие ветки 

 
lex ©   (2004-01-08 11:19) [0]

Как на время работы программы заблокировать автозапуск CD. В WinXP есть такое событие, но оно создано при помощи RegisterWindowMessage, и его номер каждую перезагрузку разный, а название его я незнаю. Есть ли обратная функция - из номера события в текст?

www.lendasoft.narod.ru


 
Игорь Шевченко ©   (2004-01-08 12:06) [1]

With systems that have Shell version 4.70 and later, Microsoft® Windows® sends a "QueryCancelAutoPlay" message to the foreground window. Your application can respond to this message to suppress AutoRun. This approach is used by system utilities such as the Open common dialog box to disable AutoRun. You will not get a "QueryCancelAutoPlay" message with versions of Windows 95 that do not have the Microsoft Internet Explorer 4.0 integrated Shell installed.

The following code fragments illustrate how to set up and handle this message. Your application must be running in the foreground window. First, register "QueryCancelAutoPlay" as a Windows message:

uMessage = RegisterWindowMessage(TEXT("QueryCancelAutoPlay"));
 
Your application"s window must be in the foreground to receive this message. The message handler should return TRUE to cancel AutoRun and FALSE to enable it.


 
Kerk ©   (2004-01-08 12:06) [2]

а причем тут событие?
при старте программы выключай autorun, при завершении включай


 
lex ©   (2004-01-14 07:37) [3]

Игорь Шевченко спасибо за ответ.
Kerk нужна ведь перезагрузка??



Страницы: 1 вся ветка

Текущий архив: 2004.03.28;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.024 c
1-1078725988
DRUID
2004-03-08 09:06
2004.03.28
Создание файла с ресурсами.


3-1077184074
maratvg
2004-02-19 12:47
2004.03.28
Компоненты для работы с клиент-серверными базами данных


14-1077827075
Petr V. Abramov
2004-02-26 23:24
2004.03.28
Закрытие исходникоа процедур в FireBird


3-1077381952
HMT
2004-02-21 19:45
2004.03.28
Что "правильнее" использовать при построении систем склад-учёта?


4-1074053732
Sirus
2004-01-14 07:15
2004.03.28
Как из DLL отослать сообщение вызывающему приложению??