Skriptanpassung für Tai-Pan mit dem Online-Manager (32bit)
Hier beispielhaft der anzupassende Teil des Taipan-Skripts "Kursupd.bas":
Function ProcessFiles(Listfilename)
Dim AbrufDatDatei
Dim Filename
Dim ExpandErfolgreich
Dim Result
' *** neu:
Dim WshShell
Dim MCBPath
' *** Ende neu
Result = True
Status.Text1 = "Dateien verarbeiten"
Status.Text2 = ""
Status.Text3 = ""
Status.Animation = atDatabase
On Error Resume Next
' *** neu:
Set WshShell = CreateObject("WScript.Shell")
MCBPath = "c:\mcblp" ' **** wichtig: ANPASSEN
AN DAS EIGENE SYSTEM!!!
' *** Ende neu
Set AbrufDatDatei = Application.OpenText (Application.TaiPanPath
& "\" & Listfilename, fmRead)
If Err.Number = 0 Then
On Error Goto 0
Do While AbrufDatDatei.IsEOF = False And Result
= True
Status.Text1 = "Dateien
verarbeiten"
Filename = AbrufDatDatei.ReadLine()
if Len(Filename) > 0
Then
Application.DeleteTempFiles
Application.ExpandData
Application.TempPath & "\" & Filename, Application.TempPath
Status.TaskList.Item(Status.ActualTask).Status
= "Importiere..."
' *** neu:
if MCBPath <> "" then
WshShell.Run "xcopy daten\*.exe " & MCBPath &
"\in\packed\",5,TRUE
end if
' *** Ende neu
Application.Import
Filename
Application.ExpandState
Application.TempPath & "\" & Filename, Application.ActualPath
Status.Progress.Pos
= 100
Status.TaskList.Item(Status.ActualTask).Status
= "Abgeschlossen."
Status.NextTask
End If
Loop
AbrufDatDatei.Close
Else
CreateErrorMsg "Die Datei '" &
Listfilename & "' konnte nicht geöffnet werden.", Err.Description
Result = False
End If
' *** neu:
if MCBPath <> "" then
WshShell.Run MCBPath & "\update.bat",5,TRUE
end if
Set WshShell = nothing
' *** Ende neu
Application.FinishImport
Status.Animation = atNone
On Error Goto 0
ProcessFiles = Result
End Function
GO! home
|