- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
This is another case of the other guy's computer not working. I've written a custom UI (WPF) that utilizes vault api to get file, folder, and item data from vault, then download files to user's desktop. Very simplistic, no vault api forms being used, written so the user can find files in a structured and safe read-only mode. Here is my code for connecting to vault.
Public Shared Function LoginVault() As Vault.Currency.Connections.Connection
Dim sec As Security = Security.Instance
Dim strVaultServer As String = sec.VaultServer
Dim strVault As String = sec.VaultVault
Dim strUser As String = sec.VaultViewerUsername
Dim strPassword As String = sec.VaultViewerPassword
Dim lgResults As Vault.Results.LogInResult =
VDF.Vault.Library.ConnectionManager.LogIn(strVaultServer, strVault, strUser, strPassword, VDF.Vault.Currency.Connections.AuthenticationFlags.Standard, Nothing)
If lgResults.Success = True Then
Return lgResults.Connection
Else
Dim strErrorMessages As String = String.Empty
For Each ErrMsg As KeyValuePair(Of Vault.Results.LogInResult.LogInErrors, String) In lgResults.ErrorMessages
strErrorMessages += Vault.Results.LogInResult.LogInErrors.GetName(GetType(Vault.Results.LogInResult.LogInErrors), ErrMsg.Key) & vbCr & ErrMsg.Value & vbCr
Next
MsgBox("Unable to log into vault." & vbCr & strErrorMessages)
Dim ehLogin As New ErrorHandler(New System.Exception(strErrorMessages & strVaultServer & " ; " & strVault & " ; " & strUser & " ; " & strPassword))
ehLogin.QuietlyHandleIt()
Try
If MsgBox("Attempt manual login?", MsgBoxStyle.YesNo, "Vault Connection") = MsgBoxResult.Yes Then
Dim conn As Vault.Currency.Connections.Connection = Nothing
conn = LoginVaultManually()
Return conn
End If
Catch ex As Exception
Dim eh As New ErrorHandler(ex)
eh.HandleIt()
End Try
End If
Return Nothing
End FunctionRecently I updated it to display the errors from logging in for best quality control. On my own machine (which has vault client installed) everything works fine here. On my test computer, I get the error "Incompatible version, can't get a license". Initially I thought that may be related to the dlls that came with the SDK vs the updated 2017.0.2 version. First of all I don't need it to get a license, I really only want read only access. A select few windows 7 computers before today were also complaining about "InvalidServer;Could not load file or assembly 'Autodesk.Connectivity.WebServices.Interop.dll' or one of its dependencies. The specified module could not be found."
My references for this project are:
Autodesk.Connectivity.WebServices (Copy Local, ver 22.0.0.0, per visual studio)
Autodesk.Connectivity.WebServices.Interop (Copy Local, ver 22.0.0.0, per visual studio)
Autodesk.Connectivity.WebServices.WCF (Copy Local, ver 22.0.56.0, per visual studio)
Autodesk.DataManagement.Client.Framework (Copy Local, ver 22.0.0.0, per visual studio)
Autodesk.DataManagement.Client.Framework.Vault (Copy Local, ver 22.0.0.0, per visual studio)
I also added clmloader.dll to the project,by using the method of manually copying the files to the project folder, and adding it to the project, then setting it as Build Action: Content, Copy to Output Direct: Copy always.
Is there a 2017.0.2 sdk set of dll's I should be using?
This setup worked ok for 4 months, until this update. Now It doesn't. Please help me to fix it.
Thanks,
Solved! Go to Solution.

