Emiel Wieldraaijer Posted November 10, 2007 Share Posted November 10, 2007 (edited) Hi All, I've got a problem with menu with icon's and the 3.2.9.x beta i get the following errors C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(18,38) : ERROR: $SRCCOPY previously declared as a 'Const' Global Const $SRCCOPY = 0x00CC0020 ~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(25,37) : ERROR: $WM_DRAWITEM previously declared as a 'Const' Global Const $WM_DRAWITEM = 0x002B ~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(26,39) : ERROR: $WM_MEASUREITEM previously declared as a 'Const' Global Const $WM_MEASUREITEM = 0x002C ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(32,33) : ERROR: $SM_CXSMICON previously declared as a 'Const' Global Const $SM_CXSMICON = 49 ~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(33,35) : ERROR: $SM_CXMENUCHECK previously declared as a 'Const' Global Const $SM_CXMENUCHECK = 71 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(42,40) : ERROR: $DT_VCENTER previously declared as a 'Const' Global Const $DT_VCENTER = 0x00000004 ~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(43,43) : ERROR: $DT_SINGLELINE previously declared as a 'Const' Global Const $DT_SINGLELINE = 0x00000020 ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~^ C:\Program Files\AutoIt3\beta\Include\ModernMenuLibSimple.au3(44,40) : ERROR: $DT_NOCLIP previously declared as a 'Const' Global Const $DT_NOCLIP = 0x00000100 ~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~^ C:\proggen\test.au3 - 8 error(s), 0 warning(s) i'm using the following code.. with 3.2.8.1 the problem does not exist.. must there be something changed ? #include <GUIConstants.au3> #include <ModernMenuLibSimple.au3> $flg = BitOR($GUI_SS_DEFAULT_GUI, $WS_DLGFRAME, $DS_MODALFRAME, $DS_SETFOREGROUND, $WS_CAPTION, $WS_SYSMENU) $flg = BitAND($flg, Not $WS_MAXIMIZEBOX, Not $WS_MINIMIZEBOX) $Count = 0 $parent = GUICreate("GUI", 450, 170, -1, -1, $flg) $filemenu = GUICtrlCreateMenu("&File") $filemenuexit = _GUICtrlCreateODMenuItem ("E&xit", $filemenu, 'shell32.dll', 27) GUISetIcon("shell32.dll", -3) TraySetToolTip("GUI") TraySetIcon("shell32.dll", -3) $EB = GUICtrlCreateButton("E&xit", 352, 80, 80, 20, BitOR($GUI_SS_DEFAULT_BUTTON, $BS_DEFPUSHBUTTON)) GUISetState(@SW_SHOW, $Parent) While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Or $msg = $EB or $msg = $filemenuexit Then Exit EndIf WEnd I've attached the include file Edited November 10, 2007 by Emiel Wieldraaijer Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
Zedna Posted November 10, 2007 Share Posted November 10, 2007 Simple fix: Just comment out all constants which are defined in ModernMenuLibSimple.au3 and are source of error: "previously declared as a 'Const'" Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted November 10, 2007 Author Share Posted November 10, 2007 Hi Zedna, thnx .. the next time i'll try to comment them out before asking .. Emiel Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now