cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - If community subscription notifications are filling up your inbox you can set up a daily digest and get all your notifications in a single email. X

Version 12 upgrade and C# - where is the MKS.ManagedAPI.dll

rteifke
8-Gravel

Version 12 upgrade and C# - where is the MKS.ManagedAPI.dll

Our IT department updated our Integrity to version 12...now my PC Application no longer works. It looks like there is no longer a MKS.ManagedAPI,dll. What is the replacement for this? How do I get my C# applications back up and running

9 REPLIES 9
KartikOak
15-Moonstone
(To:rteifke)

Could you provide specifics of the version 12.0 or 12.1 or 12.2....?

Is Visual Studio Integration the point of failure?

Integrity 12.2.1.1

Build 8

API Version: 4.16.8

 

This is the function call that fails:

APIFactory.MKSInitialize();

Unable to load DLL 'mksapi.dll' is the message

KartikOak
15-Moonstone
(To:rteifke)

Couple of questions - 

Are you using Visual Studio Integration? If not, how did you get this DLL and where are you using it?

Which release did you upgrade from?

 

We are upgrading from Release 11

Even with this code snippet it fails
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;

namespace Test
{
using mksIntegrationPoint = System.IntPtr;
using mksrtn = System.UInt32;

public partial class Form1 : Form
{
[DllImport("mksapi.dll")]
// MKS_API(mksrtn) mksCreateLocalAPIConnector(mksIntegrationPoint *ip,
// unsigned short apiMajorVersion,
// unsigned short apiMinorVersion,
// unsigned short autostart);
public static extern mksrtn mksCreateLocalAPIConnector(out mksIntegrationPoint ip,
ushort apiMajorVersion,
ushort apiMinorVersion,
ushort autostart);

public Form1()
{
InitializeComponent();
test();
}
private void test()
{
mksIntegrationPoint msp;
mksCreateLocalAPIConnector(out msp, 4, 16, 1);

}
}
}

The computers path is
PATH=c:\Program Files (x86)\Microsoft F#\v4.0\;c:\Program Files (x86)\Microsoft Visual Studio 10.0\VSTSDB\Deploy;c:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\;c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN;c:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\Tools;c:\Windows\Microsoft.NET\Framework\v4.0.30319;c:\Windows\Microsoft.NET\Framework\v3.5;c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\VCPackages;C:\Program Files (x86)\HTML Help Workshop;c:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin\NETFX 4.0 Tools;c:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin;C:\KBApps\Integrity\IntegrityClient12\bin; C:\KBApps\Integrity\IntegrityClient12\bin32;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\LonWorks\Bin;C:\KBApps\Integrity\IntegrityClient11\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Progra~2\EignerPLM\axalant\bin\intel-ms-nt4.0;C:\Progra~2\EignerPLM\ext\bin\intel-ms-nt4.0;C:\Program Files (x86)\Enterprise Vault\EVClient\;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files\Git\cmd;C:\Program Files (x86)\Microsoft Emulator Manager\1.0\;C:\Enabler\Server\Bin;C:\Program Files (x86)\PTC Integrity Modeler\Modeler\ItsShadow\Exe;C:\kbApps\HashiCorp\Vagrant\bin;C:\Users\teifker\AppData\Local\Microsoft\WindowsApps;

Microsoft Visual Studio 2010

Version 10.0.40219.1 SP1Rel

Microsoft .NET Framework Version 4.8.03761 SP1Rel

Microsoft Visual C# 2010 01018-532-2002181-70261

Microsoft Visual C# 2010

KartikOak
15-Moonstone
(To:rteifke)

Thanks for confirming that you are trying Visual Studio with 12.2.1.1

The Visual Studio version supported for that release is Visual Studio 2015 & 2017, please try with the updated version. If this continues to be an issue - please file a Case with PTC Technical Support.

 

On a side note, since you are moving from 11.x to 12.x, I would suggest you review the Platform & Integration guides along with the user guides of your focus area. 

I loaded Visual Studio 2017 and it made no difference
KartikOak
15-Moonstone
(To:rteifke)

Thanks for taking the necessary steps, please file a Case with PTC Technical Support

I found that adding the whole path of the dll got the code snippet to work...but this does not answer my original question WHAT happened to the MKS.MangedAPI.dll and the way that interface worked.

else

Does anyone an example of viewissue using this new C# interface? Or can anyone point me to C# documentation?

Top Tags