home *** CD-ROM | disk | FTP | other *** search
/ PC Professionell 2006 June / PCpro_2006_06.ISO / files / mstools / vkeyinst.EXE / VkeyInst.msi / vkey.chm / html / showme_code.vbs < prev    next >
Encoding:
Text File  |  2001-04-16  |  5.5 KB  |  115 lines

  1. Dim L_ShowMe_ErrorMessage(10)
  2. Dim msouierrSuccess
  3. Dim msouierrFail
  4. Dim msouierrNotValidId
  5. Dim msouierrNoDialog
  6. Dim msouierrWrongDialog
  7. Dim msouierrAdminDisabled
  8. Dim msouierrDisabled
  9. Dim msouierrOn
  10. Dim msouierrOff
  11. Dim msouierrUnknown
  12. Dim msouierrAppModal
  13. Dim sSecurityMSG
  14.  
  15. 'LOCALIZABLE: There needs to be a "Dim" statement for each "L_Security??_ErrorMessage" constant:
  16.     Dim L_SecurityT1_ErrorMessage
  17.     Dim L_SecurityT2_ErrorMessage
  18.     Dim L_SecurityE1_ErrorMessage
  19.     Dim L_SecurityE2_ErrorMessage
  20.     Dim L_SecurityE3_ErrorMessage
  21.     Dim L_SecurityE4_ErrorMessage
  22.     Dim L_App_DialogTitle
  23.  
  24.  
  25. '------------------------
  26. ' Detect if IE is >=4.0 -
  27. '------------------------
  28. Function DetectBrowserVersion()
  29.    Dim iVersion
  30.    iVersion=navigator.appversion
  31.    If Left(iVersion,1)>=4 Then
  32.        DetectBrowserVersion="4.0>"
  33.    Else
  34.        DetectBrowserVersion="3.0x"
  35.    End if
  36. End Function
  37.  
  38. '----------------------------------------
  39. ' Display the appropriate error message -
  40. '----------------------------------------
  41.  
  42. Sub DisplayError(retVal)
  43.     Call InitConstants
  44.     Msgbox L_ShowMe_ErrorMessage(retVal), 4144, L_APP_DialogTitle
  45. End Sub
  46.  
  47. Sub InitConstants()
  48.     'NON-LOCALIZABLE: Return values from OUACtrl.ocx. Used by the "Show Me" jumps.
  49.    msouierrSuccess=0
  50.    msouierrFail=1
  51.    msouierrNotValidId=2
  52.    msouierrNoDialog=3
  53.    msouierrWrongDialog=4
  54.    msouierrAdminDisabled=5
  55.    msouierrDisabled=6
  56.    msouierrOn=7
  57.    msouierrOff=8
  58.    msouierrUnknown=9
  59.    msouierrAppModal=10
  60.  
  61.    'LOCALIZABLE: Possible error messages displayed to the user, in order of frequency
  62.    L_ShowMe_ErrorMessage(msouierrFail)="Dieser Task kann nicht automatisch abgeschlossen werden. Fⁿhren Sie die letzten Schritte manuell durch."        'Message to display when there is a general Show Me failure
  63.    L_ShowMe_ErrorMessage(msouierrAppModal)="Es wird bereits ein Dialogfeld angezeigt."                                                                'Message to display when the application is already displaying a dialog
  64.    L_ShowMe_ErrorMessage(msouierrDisabled)="Dieser Task kann nicht automatisch abgeschlossen werden. Fⁿhren Sie die letzten Schritte manuell durch."    'Message to display when the application is in a state that makes the feature disabled
  65.    L_ShowMe_ErrorMessage(msouierrNoDialog)="Das Dialogfeld wurde nicht angezeigt."                                                                'Message to display when the application doesn't display the requested dialog
  66.    L_ShowMe_ErrorMessage(msouierrAdminDisabled)="Der Befehl, den Sie verwenden m÷chten, wurde vom Administrator deaktiviert."    'Message to display when the feature we're trying to use is disabled by an administrator
  67.    L_ShowMe_ErrorMessage(msouierrWrongDialog)="Die Option ist im angegebenen Dialogfeld nicht vorhanden."                                'Message to display when we attempt to "click" a non-existent control on a dialog ("Do It" jumps -- not really used)
  68.    L_ShowMe_ErrorMessage(msouierrNotValidId)="Interner Fehler. Fⁿhren Sie die letzten Schritte manuell durch."                                        'Message to display when our Show Me code calls the wrong TCID (This should never display!)
  69.    
  70.  
  71.    '***********************************************************************************
  72.    'NOTE TO VENDORS: These string resources need to be the same as the ones in
  73.    '              "IE 3.0x Fixes.xls"!!  Please do the following:
  74.    '                 - Click the "Copy MsgBox" on the worksheet.
  75.    '                 - Remove the existing lines below between "BEGIN" and "END"
  76.    '                 - Paste the contents of the clipboard between "BEGIN" and "END"
  77.    '                 - Insert a "Dim" statement at the top of this file for each
  78.     '                   constant
  79.     '
  80.    '*** BEGIN *** BEGIN *** BEGIN *** BEGIN *** BEGIN *** BEGIN *** BEGIN *** BEGIN ***
  81.  
  82.         'LOCALIZABLE: Problem/Solution style dialog for "Security setting too high"
  83.         L_SecurityT1_ErrorMessage="Diese Prozedur kann von der Hilfe nicht angezeigt werden, da im Browser eine zu hohe Sicherheitseinstellung festgelegt wurde"    'Line 1 of problem text
  84.         L_SecurityT2_ErrorMessage="oder das ActiveX-Steuerelement ""Ouactrl.ocx"" nicht ordnungsgemΣ▀ installiert ist."                                                    'Line 2 of problem text
  85.         L_SecurityE1_ErrorMessage="- WΣhlen Sie im Browser eine niedrigere Sicherheitseinstellung."                                                                    'Line 1 of solution text
  86.         L_SecurityE2_ErrorMessage="- Wenn diese Meldung angezeigt wird, nachdem eine niedrigere Sicherheitseinstellung ausgewΣhlt wurde, wenden Sie sich an den Systemadministrator, "        'Line 2 of solution text
  87.         L_SecurityE3_ErrorMessage="um Hilfe bei der Problembehandlung der Installation des ActiveX-Steuerelements ""Ouactrl.ocx"" zu erhalten,"        'Line 3 of solution text
  88.         L_SecurityE4_ErrorMessage="  das sich im Installationsordner von Microsoft Office befindet."                                                        'Line 4 of solution text
  89.  
  90.         'LOCALIZABLE: 
  91.         sSecurityMSG=L_SecurityT1_ErrorMessage & Chr(13) & L_SecurityT2_ErrorMessage & Chr(13) & Chr(13) & L_SecurityE1_ErrorMessage & Chr(13) & L_SecurityE2_ErrorMessage & Chr(13) & L_SecurityE3_ErrorMessage & Chr(13) & L_SecurityE4_ErrorMessage
  92.  
  93.         'LOCALIZABLE: Title for error dialogs
  94.         L_App_DialogTitle="Microsoft Office-Hilfe"        'Title for error dialogs
  95.     
  96.    '*** END *** END *** END *** END *** END *** END *** END *** END *** END *** END ***
  97.     
  98. End Sub
  99.  
  100. Sub InitErrorMsgs()
  101.     'Leave this here just in case we forgot to remove a call.
  102. End Sub
  103.  
  104. '---------------------------------------------
  105. ' Mouse over, mouse out, rollover procedures -
  106. '---------------------------------------------
  107. Sub ColorSteps(sColor)
  108.     If sColor="LightBlue" Then
  109.         steps.className = "Highlight"
  110.     Else
  111.         steps.className = "Normal"
  112.     End If
  113. End Sub
  114.  
  115.