Import - Export

<< Click to Display Table of Contents >>

Navigation:  General questions >

Import - Export

 

Questions and answers about OMNITRACKER ↦ General questions ↦ Import - Export:

 

How to add the current date to the file name of an automated export task?

The string of the target file name has to be split and the date has to be inserted.

Example (file type .pdf):
targetfilename = Left(targetfilename, Len(targetfilename)-4) & Date & ".pdf"

 

LDAP import fails or no connection can be established.

The following script can be used for troubleshooting. It imitates the LDAP access by OMNITRACKER. As in OMNITRACKER, the ADSI objects from Microsoft are used.

strConnect = "LDAP://myhost.mydomain.local:389"
strPrefix = ""
strConnect = InputBox("Bitte den LDAP-Verbindungsstring angeben (z.B. '" & strConnect & "')", , strConnect)
strUser = InputBox("Bitte Benutzername eingeben", "LDAP-Anmeldung")
trPwd = InputBox("Bitte Passwort eingeben", "LDAP-Anmeldung")
If (strConnect <> "") Then

If strUser <> "" Then
Set dso = GetObject("LDAP:")
Set obj = dso.OpenDSObject(strConnect, strUser, strPwd, &H201)
Else
Set obj = GetObject(strConnect)
End If
strSchemaPath = obj.Schema

Set objSchemaObj = GetObject(strSchemaPath)
strParentPath = objSchemaObj.Parent
Set objSchemaRoot = GetObject(strParentPath)

nLen = Len(strPrefix)
s = ""
nCnt = 0
For Each objSchema In objSchemaRoot
strName = objSchema.Name
If (objSchema.Class = "Class") Then
If (strPrefix = "" Or Left(strName, nLen) = strPrefix) Then
s = s & objSchema.Name & vbCrLf
nCnt = nCnt + 1
End If
End If
Next

strMsg = "Found " & nCnt & " classes"
If (strPrefix <> "") Then
strMsg = strMsg & " with prefix '" & strPrefix & "'"
End If
strMsg = strMsg & ":" & vbCrLf & "(Schema path = '" & strParentPath & "')" & vbCrLf & vbCrLf & s
MsgBox strMsg
End If

With the help of this script the system settings can be adjusted so that the desired classes are listed.