Click here to Skip to main content
15,907,183 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to add a scrollbar in popup menu Pin
FT pere21-Apr-03 0:29
sussFT pere21-Apr-03 0:29 
QuestionHow to create ListView with _always_visible_vertical_scroll_bar_ ? Pin
s_k21-Apr-03 0:03
s_k21-Apr-03 0:03 
AnswerRe: How to create ListView with _always_visible_vertical_scroll_bar_ ? Pin
KVRN Kiran Kumar21-Apr-03 1:31
KVRN Kiran Kumar21-Apr-03 1:31 
GeneralRe: Copying and Pasting file of any type Pin
dabs21-Apr-03 4:43
dabs21-Apr-03 4:43 
GeneralQuestion about local variable used as a reference. Pin
George220-Apr-03 22:18
George220-Apr-03 22:18 
GeneralRe: Question about local variable used as a reference. Pin
Joaquín M López Muñoz20-Apr-03 22:36
Joaquín M López Muñoz20-Apr-03 22:36 
GeneralRe: Question about local variable used as a reference. Pin
George220-Apr-03 23:27
George220-Apr-03 23:27 
GeneralURGENT HELP REQUIRED:mad: Pin
Cyberizen20-Apr-03 22:01
Cyberizen20-Apr-03 22:01 

Hi ppl
well my problem is with explicit linking here.Actually there is this function called "SetLayeredWindowAttributes" that i want to link explicitly following is the code:

typedef BOOL (CALLBACK*LPFNSETLAYEREDWINDOWATTRIBUTES)(COLORREF,BYTE,DWORD);

...

BOOL CMainFrame ::TranparentWindow()
{
HINSTANCE hDLL; // Handle to DLL
LPFNSETLAYEREDWINDOWATTRIBUTES lpfnSetLayeredWindowAttributes; // Function pointer
COLORREF color = RGB(100,100,100);
BYTE alpha;
DWORD what;


hDLL = LoadLibrary(_T("USER32.DLL"));
if (hDLL != NULL)
{
lpfnSetLayeredWindowAttributes = (LPFNSETLAYEREDWINDOWATTRIBUTES)GetProcAddress(hDLL,"SetLayeredWindowAttributes");
if (!lpfnSetLayeredWindowAttributes)
{
// handle the error
FreeLibrary(hDLL);
return FALSE;
}
else
{
// call the function
BOOL status;
status = lpfnSetLayeredWindowAttributes(color,alpha,what);
}
}
}

I am calling this function on the OnCreate message handler there are no linker problems as well when the program is executed it give me an error regarding ESP tellimg me something about conflicting calling conventions anyone having any idea wats the problem here please do tell me

Thanks in advance

Ahmed Ajmal
GeneralRe: URGENT HELP REQUIRED:mad: Pin
Joaquín M López Muñoz20-Apr-03 22:39
Joaquín M López Muñoz20-Apr-03 22:39 
QuestionWhere can I find tutorial about interface? Pin
George220-Apr-03 21:56
George220-Apr-03 21:56 
GeneralTemplate overriding of operator [] Pin
Alexandru Savescu20-Apr-03 21:20
Alexandru Savescu20-Apr-03 21:20 
GeneralRe: Template overriding of operator [] Pin
Joaquín M López Muñoz20-Apr-03 21:51
Joaquín M López Muñoz20-Apr-03 21:51 
GeneralTiming problem in run-time loading DLL Pin
pklim20-Apr-03 20:17
pklim20-Apr-03 20:17 
QuestionCListCtrl: AutoArrage & Ascending Sort? Pin
Bùi Phạm Minh Trí20-Apr-03 16:56
Bùi Phạm Minh Trí20-Apr-03 16:56 
GeneralQuestion about a edit box! Help! Pin
dxhdxh20-Apr-03 14:09
dxhdxh20-Apr-03 14:09 
GeneralRe: Question about a edit box! Help! Pin
Nick Parker20-Apr-03 16:57
protectorNick Parker20-Apr-03 16:57 
GeneralRe: Question about a edit box! Help! Pin
DuFF21-Apr-03 7:08
DuFF21-Apr-03 7:08 
GeneralI need help with MATLAB questions Pin
nxz420-Apr-03 11:17
nxz420-Apr-03 11:17 
GeneralRe: I need help with MATLAB questions Pin
Nick Parker20-Apr-03 16:51
protectorNick Parker20-Apr-03 16:51 
GeneralRe: I need help with MATLAB questions Pin
Anonymous20-Apr-03 21:52
Anonymous20-Apr-03 21:52 
GeneralRe: I need help with MATLAB questions Pin
Toni7821-Apr-03 11:58
Toni7821-Apr-03 11:58 
GeneralUsing the serial com port Pin
Q15002220-Apr-03 10:05
Q15002220-Apr-03 10:05 
GeneralRe: Using the serial com port Pin
anju20-Apr-03 17:38
anju20-Apr-03 17:38 
GeneralRe: Using the serial com port Pin
Toni7821-Apr-03 11:53
Toni7821-Apr-03 11:53 
GeneralWorker-Thread In Win32 Application Pin
ZarrinPour20-Apr-03 5:27
ZarrinPour20-Apr-03 5:27 

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.