Kbase P3194: How To Automatically Register an ActiveX Control From a Progress Session?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  9/20/2002 |
|
Solution ID: P3194
GOAL:
How to automatically register an ActiveX control from a Progress session?
FACT(s) (Environment):
Progress 9.x
Windows
FIX:
DEFINE VARIABLE cFileName AS CHARACTER NO-UNDO.
DEFINE VARIABLE cWinSystem AS CHARACTER NO-UNDO.
DEFINE VARIABLE cWinDir AS CHARACTER NO-UNDO.
DEFINE VARIABLE cSource AS CHARACTER NO-UNDO.
ASSIGN cSource = ""
cFileName = ""
cWinDir = OS-GETENV("Windir") + "\".
IF OS-GETENV("OS") = "Windows_NT" THEN
cWinSystem = cWinDir + "SYSTEM32\" .
ELSE
cWinSystem = cWindir + "SYSTEM\" .
MESSAGE "Copying file " + cFileName SKIP " From: " + cSource SKIP " To " + cWinSystem VIEW-AS ALERT-BOX.
OS-COPY VALUE(cSource + cFileName) VALUE(cWinSystem + cFileName).
/* Register the ActiveX control */
OS-COMMAND NO-WAIT VALUE(cWinSystem + "regsvr32.exe " + cFileName) .