I am getting error 'Could not find server' while logging in to ePDM using various login APIs available.
Any help appreciated.
Can you post your code so that we know what you've tried? It's easiest to troubleshoot code when I can look at it step by step.
Thanks for your response Alex.
I am trying with :
IEdmVault15 vault = new EPDM.Interop.epdm.EdmVault5Class() as IEdmVault15;
vault.LogInWindowsUser(<Username>, <Password>, <VaultName>);
I also tried with
vault.LoginEx(<Username>, <Password>, <VaultName>, 0);
vault.Login(<Username>, <Password>, <VaultName>, 0);
Its throwing the same error : The server was not found
I generally get the vault name fro the active doc.
Dim vault As EdmVault5
Set vault = New EdmVault5
' Debug.Print "Vault object was set to new EdmVault5"
Dim vaultname As String
vaultname = vault.GetVaultNameFromPath(path_to_file)
' Debug.Print "Vault name = " & vaultname
vault.LoginAuto vaultname, 0
' Debug.Print "Vault was logged in"
Also make sure yo have the Reference file for whatever version of sw/pdm you are running
Hope this helped
I tried the LoginAuto method as well, but same error.
It looks like, the credentials gets validated & then throwing the exception.
Some details on exception :
The following database error has occured:
State:08001,Native:17,Origin:[Microsoft][ODBC SQL Server Driver][DBNETLIB]
State:01000,Native:5,Origin:[Microsoft][ODBC SQL Server Driver][DBNETLIB]
SQL Server does not exist or access denied.
Error code: E_EDM_DATABASE_ACCESS
It's still a bit difficult to tell exactly what is going on. It did just cross my mind to make sure you have PDM Professional. The standard version does not allow the use of API for anything.
Typically to log in to the vault, I use the following logic to get into PDM.
// Automatically log in to vault
Trace.WriteLine("Not logged in, auto log in");
This will check if a user has logged in via Windows Explorer on the PC. If they haven't, it will pop up the blue log-in prompt and have the user log in.
Once the vault is logged in, you can access the data as your normally would.
Retrieving data ...