Jump to content
  • Advertisement
Sign in to follow this  

Problem adding shield icon to buttons in my atl/wtl application

This topic is 3286 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

i, i'm have a problem with adding the shield icons to the buttons in my application. I am running under windows vista, using visual studio 2008 and it is a dll i am generating. I added the following code in the in the OnInitDialog() part: Button_SetElevationRequiredState(hwnd, TRUE); class ATL_NO_VTABLE MyClass: public CComObjectRootEx<CComSingleThreadModel>, public CComCoClass<MyClass , &CLSID_MyClass>, public IPropertyPageImpl<MyClass>, public CDialogImpl<MyClass>, public CWinDataExchange<MyClass> { BEGIN_MSG_MAP(MyClass) MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog) REFLECT_NOTIFICATIONS() END_MSG_MAP() }; MyClass::OnInitDialog() { Button_SetElevationRequiredState(hwnd, TRUE); HWND hwnd = GetDlgItem(IDC_RULE_BUTTON); int result = Button_SetElevationRequiredState(hwnd, TRUE); } I have added the manifest part to load Microsoft Common Controls 6.0: <dependentAssembly> <assemblyIdentity type='win32' name='Microsoft.Windows.Common-Controls' version='' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*' /> </dependentAssembly> Using the dependency walker application to check the dll file generatedi can see that it is using two COMCTL32.DLL, one with file version 5.82 and another one with version 6.10. Can this cause problems in vista applications? Any other suggestions on what the problem can be?

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!