HI,
I am trying to create an Agent from vb .net using domino com object.
Here is my code, I got exception error when the statement
'importer.import(stream,db). will anyone help me out?
Dim session As New Domino.NotesSession
Dim thisdb As NotesDatabase
Dim stream As NotesStream
Dim importer As NotesDXLImporter
session.Initialize()
session.GetDatabase("", "kmanohar.nsf", True)
stream = session.CreateStream()
Dim fileName As String = "c:\\dxl\\mur_test_new.xml"
If Not stream.Open(fileName) Then
MessageBox.Show("File could not Open", "File Opening")
Exit Sub
End If
If stream.Bytes = 0 Then
MsgBox("File did not exist or was empty" & fileName)
Exit Sub
End If
importer = session.CreateDXLImporter
importer.ReplaceDBProperties = False
importer.ReplicaRequiredForReplaceOrUpdate = False
importer.ACLImportOption = Domino.DXLIMPORTOPTION.DXLIMPORTOPTION_IGNORE
importer.DesignImportOption = Domino.DXLIMPORTOPTION.DXLIMPORTOPTION_CREATE
importer.UnknownTokenLogOption = DXLLOGOPTION.DXLLOGOPTION_IGNORE
Try
importer.Import(stream, thisdb)
Catch ex As Exception
MsgBox(ex.ToString, MsgBoxStyle.ApplicationModal, "Import Agent")
End Try
stream.Close()