sdaiCreateInstanceBNEI

This call creates an instance at a specific given express ID, the instance is only created if the express ID was not used yet.

Syntax

public const string enginedll = @"engine.dll";

[DllImport(enginedll, EntryPoint = "sdaiCreateInstanceBNEI")]
public static extern Int32 x86_sdaiCreateInstanceBNEI(Int32 model, string entityName, Int64 expressID);

[DllImport(enginedll, EntryPoint = "sdaiCreateInstanceBNEI")]
public static extern Int32 x64_sdaiCreateInstanceBNEI(Int64 model, string entityName, Int64 expressID);

public static Int32 sdaiCreateInstanceBNEI(Int64 model, string entityName, Int64 expressID)
		{
			if (IntPtr.Size == 4)
			{
				var _result = x86_sdaiCreateInstanceBNEI((Int32)model, entityName, expressID);
				return _result;
			}
			else
			{
				return x64_sdaiCreateInstanceBNEI(model, entityName, expressID);
			}
		}

[DllImport(enginedll, EntryPoint = "sdaiCreateInstanceBNEI")]
public static extern Int32 x86_sdaiCreateInstanceBNEI(Int32 model, byte[] entityName, Int64 expressID);

[DllImport(enginedll, EntryPoint = "sdaiCreateInstanceBNEI")]
public static extern Int32 x64_sdaiCreateInstanceBNEI(Int64 model, byte[] entityName, Int64 expressID);

public static Int32 sdaiCreateInstanceBNEI(Int64 model, byte[] entityName, Int64 expressID)
		{
			if (IntPtr.Size == 4)
			{
				var _result = x86_sdaiCreateInstanceBNEI((Int32)model, entityName, expressID);
				return _result;
			}
			else
			{
				return x64_sdaiCreateInstanceBNEI(model, entityName, expressID);
			}
		}    

Property model

Size: 32 bit / 4 byte (value)
The handle to the model. The model handle is static during its existance. Several models can be opened simultaniously within one session. Different models are always independent, threads are allowed to be running on different models simultaniously.

Property entityName

Size: 32 bit / 4 byte (reference)
...

Property expressID

Size: 64 bit / 8 byte (value)
...