MS1901
This commit is contained in:
@@ -614,7 +614,7 @@ Public Class ClassWindream
|
||||
Dim dmsServer As String
|
||||
Dim wmbrwsr
|
||||
Dim Connect
|
||||
If LogErrorsOnly = False Then ClassLogger.Add(" >> Stream_File wurde gestartet", False)
|
||||
If LogErrorsOnly = False Then ClassLogger.Add(" >> In Create_Session....", False)
|
||||
wmbrwsr = CreateObject("WMOBrws.ServerBrowser")
|
||||
'==================================================================
|
||||
' get the current DMS-server to log in
|
||||
@@ -758,7 +758,12 @@ Public Class ClassWindream
|
||||
Dim result As MsgBoxResult
|
||||
result = MessageBox.Show(msg, "File alredy exists:", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
|
||||
If result = MsgBoxResult.Yes Then
|
||||
WMObject = oSession.GetNewWMObjectFS(WMEntityDocument, endgültigerDateiname, WMObjectEditModeObject)
|
||||
Try
|
||||
WMObject = ClassWindream.oSession.GetWMObjectByPath(WINDREAMLib.WMEntity.WMEntityDocument, endgültigerDateiname)
|
||||
Catch ex As Exception
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error in Creating WindreamObject (Stream_File):", ex.Message)
|
||||
Return False
|
||||
End Try
|
||||
Else
|
||||
Dim FILE_EXISTS_IN_WD = True
|
||||
Dim version As Integer = 2
|
||||
@@ -769,12 +774,13 @@ Public Class ClassWindream
|
||||
Do While FILE_EXISTS_IN_WD = True
|
||||
_neuername = _stammname & "~" & version
|
||||
FILE_EXISTS_IN_WD = ClassWindream.oSession.WMObjectExists(WINDREAMLib.WMEntity.WMEntityDocument, _neuername & extension, 0, 0)
|
||||
Version = Version + 1
|
||||
version = version + 1
|
||||
Loop
|
||||
endgültigerDateiname = _neuername & extension
|
||||
WMObject = oSession.GetNewWMObjectFS(WMEntityDocument, endgültigerDateiname, WMObjectEditModeObject)
|
||||
End If
|
||||
|
||||
WMObject = oSession.GetNewWMObjectFS(WMEntityDocument, endgültigerDateiname, WMObjectEditModeObject)
|
||||
|
||||
If Err.Number > 0 Then
|
||||
ClassLogger.Add(" FEHLER: Neues WMObject (Kopie) konnte nicht erzeugt werden - Error: '" & Err.Description & "'")
|
||||
'MsgBox(Err.Description)
|
||||
@@ -928,7 +934,10 @@ Public Class ClassWindream
|
||||
End Function
|
||||
Public Shared Function Delete_WDFile(ByVal WD_File As String)
|
||||
Try
|
||||
WD_File = WD_File.Substring(2)
|
||||
If WD_File.StartsWith("W") Then
|
||||
WD_File = WD_File.Substring(2)
|
||||
End If
|
||||
|
||||
Dim WMObject As WINDREAMLib.WMObject '= CreateObject("WINDREAMLib.WMObject") 'New WINDREAMLib.WMObject
|
||||
Try
|
||||
WMObject = oSession.GetWMObjectByPath(WINDREAMLib.WMEntity.WMEntityDocument, WD_File) 'WINDREAMLib.WMEntity.WMEntityDocument
|
||||
|
||||
Reference in New Issue
Block a user