ScriptUSER Posted January 4, 2007 Posted January 4, 2007 I am using th following script to identify if Msword is installed on a users computer . There are differnt versions of Word like 9 , 10 , 11 .... my code checks for vesion 10 and works if i subsiute 11 works for vr 11 . how could i modify my code to work for all versions , without additional scipting ? CODE$sPath = RegRead("HKLM\SOFTWARE\Microsoft\Office\10.0\Word\InstallRoot", "Path") If @error Then ;MsgBox(48, "Error", "MS Office 2002 is not installed.") ColorDemo5() Exit EndIf
ChrisL Posted January 4, 2007 Posted January 4, 2007 Try this Local $objWord = ObjCreate("Word.Application") If IsObj($objWord) then Msgbox (0,"","Version: " & $objWord.Caption & " " & $objWord.Version & @crlf _ & "Build: " & $objWord.Build) $objWord.Quit Else Msgbox (0,"","Word is not installed") EndIf [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire
sensalim Posted April 19, 2007 Posted April 19, 2007 RegRead("HKLM\Software\Microsoft\Windows\CurrentVersion\App Paths\winword.exe\Path") I think you mean RegRead("HKLM\Software\Microsoft\Windows\CurrentVersion\App Paths\winword.exe","Path") since it requires 2 parameters. Thanks for the code, I needed it.
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