>>Hi
>>
>>I am trying to get the name, and path of an applications associated icon
>>
>>Does any one know parameters I have to pass to
>>
>>ExtractIcon, and ExtractAssociatedIcon API.
>>
>>I think I have the correct systax,bur I get an exception error when I run my code.
>>
>>I am trying to pass the window handle, the file path & name, but I am not really sure how I should pass the third argument, as it is a WORD TYPE.
>>any help or example of this in VFP would be a big help
>>
>
>I don't know the API call, but a WORD is generally described as an INTEGER in the DECLARE...DLL syntax. You might want to look at Christof Lange's STRUCT class to see if he has support for the API calls you need in there.
Hey Ed,
You don't need any structures with these. The declarations are pretty straight forward. As you said INTEGER = WORD.
DECLARE INTEGER ExtractIcon IN Shell32;
INTEGER hInst, STRING @lpszExeFileName, INTEGER nIconIndex
DECLARE INTEGER ExtractAssociatedIcon IN Shell32;
INTEGER hInst, STRING @lpIconPath, INTEGER @lpiIcon
DECLARE INTEGER GetClassLong IN Win32API;
INTEGER hWnd, INTEGER nIndex
George
Ubi caritas et amor, deus ibi est