 |
|
 |
SetLayeredWindowAttributes() Not working in Windows 2000 service pack 4.
|
|
|
|
 |
|
 |
i got this error LNK2001: unresolved external symbol __imp__SetLayeredWindowAttributes@16 error when run the application, but i have added user32.lib and user32.dll and also #include Winuser.h
#include Windows.h header files. am i correct adding the file?
otherwise where will i add the lib file and other eader files and dll
Menu:
Tools->option->directries tab->lib files or
project->Setting->link
Reply soon..
Regards,
Jayender
|
|
|
|
 |
|
 |
jayender wrote: otherwise where will i add the lib file and other eader files and dll
You don't need any of that as their are already ifdef's littered all over the place that will get it done.
If your using VC++ 6.0 just add this above the VC_EXTRALEAN line in stdafx.h
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0500
#endif
If your in VC++ 2003 just modify this value in this section in stdafx.h
|
|
|
|
 |
|
 |
Hi all,
As I am a new developer for VC++ and .net so please consider my silly mistakes if I did.
I want to use some functions from .dll to my other VC++ client project. It gives no error at the time of compile but while I am going to rebuild it gives me errors this time and these error comes when I call my .dll file’s function:-
// this call gives me linking error
int x = MyCFunc(5); // this function is declare in header file of my .dll
// and error comes :-
Linking...
Creating library Debug/AP_ProductLocater.lib and object Debug/AP_ProductLocater.exp
ProductLocater.obj : error LNK2001: unresolved external symbol __imp__MyCFunc
C:\Program Files\Quark\QuarkXPress 6.1\XTension\AP_ProductLocater.xnt : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
AP_ProductLocater.xnt - 2 error(s), 0 warning(s)
I think it comes because I didn’t add any reference of my “TestFuncDll.lib“ file in my client project so I must have to include a reference of lib file… so how I add this reference in VC++6.0? if my dll name is “TestFuncDll.dll”?
And also in .net I and getting same error at the time of linking I am giving the name of TestFuncDll.lib after adding in Additional Dependencies Properties(Project Properties>>Linker>> input>> Additional Dependencies). I already have some lines in this edit box and these are:-
..\objr\PMRuntime.lib
..\objr\Public.lib
..\objr\WidgetBin.lib
now I after adding my lib file reference it becomes:-
..\objr\PMRuntime.lib
..\objr\Public.lib
..\objr\WidgetBin.lib
D:\amit\TestFuncDll\Release\TestFuncDll.lib
So is it right? What should I do for avoiding the linking error?
One more question from where it get the reference of .dll file? If I want to use this .dll from a specific location let say “c:\Onesouce\bin” then what I have to do?
Thanks a lot.
Vineet jain.
|
|
|
|
 |
|
 |
Hi,
I get the link error when I included the winldap.h file and try to call its method.
************
Linking...
Creating library Debug/LDAPLogin.lib and object Debug/LDAPLogin.exp
LDAPLogin.obj : error LNK2001: unresolved external symbol __imp__ldap_init
Debug/LDAPLogin.dll : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
************
The method name is prefixed with __imp__. Should I include any lib files or changes need to be done in the project settings so to get rid of this error.
Qucik reply will be a needful.
|
|
|
|
 |
|
 |
hi mandanani,
i am also facing same problem... did u get rid of this problem? if yes then help me out to overcome it please.
what setting did you changed in your project to get rid of this linking error?
Thanks,
Vineet jain.
|
|
|
|
 |
|
 |
I am having exactly the same problem. I tried linking with Wldap32.lib just to see if it would help, but that didn't work. If you find out how to fix this please let me know.
|
|
|
|
 |
|
 |
Hi, I don't know if you guys are still having problems with this, but I figured it out finally. Never mind what I said in my other post. You DO have to link the project with Wldap32.dll. I was just doing it wrong because I wasn't used to the compiler commands.
Doug
|
|
|
|
 |
|
 |
who can solve this problem...
why SetLayeredWindowAttributes can't used in 8 bits(256) color quality.
please tell me, thanks.
|
|
|
|
 |
|
 |
Hello,
Using GetDC(0) provides a device context for the desktop, but layered windows are not included. I assume this is because the data for the layered windows is stored in off screen memory somewhere. Is there a way to get a device context for layered windows as well?
|
|
|
|
 |
|
 |
Compiling...
SetTransPlus.cpp
SetTransPlusDlg.cpp
Generating Code...
Linking...
SetTransPlusDlg.obj : error LNK2001: unresolved external symbol __imp__SetLayeredWindowAttributes@16
Debug/SetTransPlus.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
SetTransPlus.exe - 2 error(s), 0 warning(s)
help help me !!!
|
|
|
|
 |
|
 |
you have to add the
user32.lib
to your project
find in \\programs\MSVS\VC98\lib
|
|
|
|
 |
|
 |
I have this compile error under VC++ 6.0: "unresolved external symbol __imp__SetLayeredWindowAttributes@16"
Any advice?
x meng
xmeng@nc.rr.com
|
|
|
|
 |
|
 |
I found out that a bitmap containing alpha channel can be specified to a layered window in order to obtain a special defined map alpha, not just a general level of transparence.
This is done by using the UpdateLayeredWindow function.
This is all fine, but I still have some problems:
Since I provide the look for the window throught my bitmap, the window will look just like that! This means that any controls that I have on my frame are not drawed anymore. I also can't use this stuf for children controls (windows).
One solution I think of, is to draw all the children myself over the bitmap I use to set the window look. But what can I do with other controls that I don't want to draw myself (think of an Internet browser control - I can't draw that). Maybe is a way to force windows to draw on a specified hdc ?
If anyone can help, cause I really think it's a great feathure that I can't fully use !
Alex
xelanoimis@yahoo.com
|
|
|
|
 |
|
 |
Is there a way to select which components of the window you want to make transparent. For example: an application that has floating text. Text 0% transparent all other components 100% transparent.
annation
|
|
|
|
 |
|
 |
Add the following to SetTransPlugDlg.h when converting to VC++ 7
public:
BOOL SetLayeredWindowAttributes(HWND hWnd, COLORREF crKey, BYTE bAlpha, DWORD dwFlags);
|
|
|
|
 |
|
 |
Is it possible to make and inactive window in win2000/XP transparnt?
If so, can you give an example?
LNK
|
|
|
|
 |
|
 |
IF I draw on Transparent Window Its become Transparent . How to Draw Opaque line on Transparent window ?
|
|
|
|
 |
|
 |
Did you find a way to do that? if you did, do me a favore and tell me too.
|
|
|
|
 |
|
 |
Thanks for the trick
It's just I was looking for.
|
|
|
|
 |
|
 |
The demo and src code you kindly submitted works fine on ordinary windows, yet I won't be able to make an OpenGL (suspect Direct3D also) window transparent or color key'ed. Is there any pixelformatdescriptor setting to be done for transparency purpose? or is it a matter of too frequent window refresh? or just can't work?
|
|
|
|
 |
|
 |
I am also interested in this.
I just got some thoughts:
when your window is layered, you can call GetDC and BitBlt to get the graphics under that window, say copy that into a image, then drawing the OpenGL scene to a buffer, combine that buffer with background image using alpha blending.
|
|
|
|
 |
|
 |
I am creating a program and I want my toolbar when it is undocked to be transparent but the handle that I use does not change this window. Does anyone know how to get the correct window handle that would make it work?
I know it possible to change the any control bar to transparent when it is undocked cause I tried it with your program, but I want to be able to do it in the code.
PS-Love the code
|
|
|
|
 |
|
 |
This will depend on the way your docked toolbars are implemented - sometimes (e.g. Developer Express) they will have a separate window handle for docked and floating bars.
Use Spy++ and a debugger to figure it out
|
|
|
|
 |
|
 |
i would be nice if i somehow could save the modifications to the windows. If i reboot all my modificated windows are gone
|
|
|
|
 |