Click here to Skip to main content
15,885,366 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Problems in Static LED control - CDigiStatic Pin
Semion_N12-Jul-06 7:20
Semion_N12-Jul-06 7:20 
QuestionHelp on GetAsyncKeyState(...) Pin
Uday Janaswamy11-Jul-06 21:50
Uday Janaswamy11-Jul-06 21:50 
AnswerRe: Help on GetAsyncKeyState(...) Pin
Hamid_RT11-Jul-06 22:19
Hamid_RT11-Jul-06 22:19 
GeneralRe: Help on GetAsyncKeyState(...) Pin
Uday Janaswamy11-Jul-06 23:19
Uday Janaswamy11-Jul-06 23:19 
GeneralRe: Help on GetAsyncKeyState(...) Pin
FarPointer12-Jul-06 0:08
FarPointer12-Jul-06 0:08 
GeneralRe: Help on GetAsyncKeyState(...) Pin
Hamid_RT12-Jul-06 0:59
Hamid_RT12-Jul-06 0:59 
AnswerRe: Help on GetAsyncKeyState(...) Pin
see me11-Jul-06 22:29
see me11-Jul-06 22:29 
QuestionObtaining USB flash IDs Pin
Sonic_amiga11-Jul-06 21:32
Sonic_amiga11-Jul-06 21:32 
I have a problem. I have some USB flash media and i want to use it to store some key data for my software. The data are encrypted. In order to protect the media from direct copying i want to include Vendor ID, Product ID and serial number into the encryption key.
How to obtain VID, PID and serial?
I've tried two approaches:
1. Issue IOCTL_STORAGE_QUERY_PROPERTY on the drive in order to obtain STORAGE_DEVICE_DESCRIPTOR. It looked like these parameters are present in this structure. However looks like this works correctly only for SCSI. For IDE devices VendorID field is empty (NULL), ProductID field contains drive model string obtained via Identify command, SerialNo field is also empty. For USB drive the things are even worse: Vendor = "USB", Product = "Flash disk" and no serial number.
I've tried IOCTL_STORAGE_GET_MEDIA_SERIAL_NUMBER, but on my flash drives it simply doesn't work. The documentation says it works only WinXP SP1 and only if the media is SCM-1 (Security content management)-compilant. That's all, approach no. 1 stopped here.
2. Traverse through a USB devices tree exactly in the same way as USBView does. Everything is okay, i see IDs and serials, but now i need to find out a drive letter under which the flash device is mounted from the hub name and port number? IOCTL_USB_GET_NODE_CONNECTION_NAME gives empty string on non-hubs. IOCTL_USB_GET_NODE_CONNECTION_DRIVERKEY_NAME works and gives me some ID, but what to do with it then?
Please help me.
QuestionCombineRgn for 4 regions [modified] Pin
hell_admin11-Jul-06 21:28
hell_admin11-Jul-06 21:28 
QuestionRe: CombineRgn for 4 regions Pin
Hamid_RT11-Jul-06 22:09
Hamid_RT11-Jul-06 22:09 
AnswerRe: CombineRgn for 4 regions Pin
hell_admin11-Jul-06 22:20
hell_admin11-Jul-06 22:20 
GeneralRe: CombineRgn for 4 regions Pin
Hamid_RT11-Jul-06 22:52
Hamid_RT11-Jul-06 22:52 
Questionhelp in threads Pin
Nirmal Khatri11-Jul-06 21:17
Nirmal Khatri11-Jul-06 21:17 
AnswerRe: help in threads Pin
Abhi Lahare11-Jul-06 21:35
Abhi Lahare11-Jul-06 21:35 
AnswerRe: help in threads Pin
Hamid_RT11-Jul-06 22:01
Hamid_RT11-Jul-06 22:01 
Questiondocumentation Pin
MozhdehQeraati11-Jul-06 20:39
MozhdehQeraati11-Jul-06 20:39 
AnswerRe: documentation Pin
eusto11-Jul-06 21:29
eusto11-Jul-06 21:29 
QuestionSHGetSpecialFolderLocation Pin
Maxime Labelle11-Jul-06 20:32
Maxime Labelle11-Jul-06 20:32 
AnswerRe: SHGetSpecialFolderLocation Pin
Don Box11-Jul-06 21:23
Don Box11-Jul-06 21:23 
GeneralRe: SHGetSpecialFolderLocation Pin
Maxime Labelle11-Jul-06 21:54
Maxime Labelle11-Jul-06 21:54 
AnswerRe: SHGetSpecialFolderLocation Pin
Jonas Hammarberg11-Jul-06 21:29
professionalJonas Hammarberg11-Jul-06 21:29 
GeneralRe: SHGetSpecialFolderLocation Pin
Maxime Labelle11-Jul-06 21:53
Maxime Labelle11-Jul-06 21:53 
GeneralRe: SHGetSpecialFolderLocation [modified] Pin
Jonas Hammarberg11-Jul-06 22:20
professionalJonas Hammarberg11-Jul-06 22:20 
GeneralRe: SHGetSpecialFolderLocation Pin
Maxime Labelle12-Jul-06 3:36
Maxime Labelle12-Jul-06 3:36 
QuestionDifficult to understand PrintPreview without Doc/View Pin
mikobi11-Jul-06 20:15
mikobi11-Jul-06 20:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.