Hello,
i'm a newbie to autoit and right now i'm trying to make a admin tool which will help our helpdesk fullfilling their service to our customer.
because we've got several settlements here in the german region (the emea hq and the german hq) i want to make the gui multilingual (english and german) so if a user works on a english machine he'll get the english gui and on german machines the german gui.
my code for this looks like:
$strOsLanguage = @OSLang
$strLGerman = "0407"
If $strOsLanguage = $strLGerman Then
#include <german.au3>
Else
#include <english.au3>
EndIf
$mNetwork = GUICtrlCreateMenu ($_network_)
$msPing = GUICtrlCreateMenuitem ($_ping_, $mNetwork)
$msNetPerf = GUICtrlCreateMenuitem ($_netperf_, $mNetwork)
$mSystem = GUICtrlCreateMenu ($_system_)
$msCmdPrompt = GUICtrlCreateMenuitem ($_cmd_, $mSystem)
$msComputer = GUICtrlCreateMenuitem ($_manage_, $mSystem)
The vars $_xxx_ are the language variables who are defined in the files german.au3 and english.au3 as Global Const. The If Else works, but the compiler gives me the following error message:
ERROR: $_network_ previously declared as a 'Const'
Global Const $_network_ = "Network"
$_ping_ previously declared as a 'Const'
Global Const $_ping_ = "Ping"
and so on
any hints for me? or is my approach wrong?
rgds
ty2d