GetInterfaceName

#include “BlackIceDEVMODE.h”

 

LPCTSTR     GetInterfaceName(BlackIceDEVMODE* pDevMode);

Description

Returns the value of the InterfaceName member of the BlackIceDEVMODE. The InterfaceName member stores the name of the messaging interface.

Parameters

BlackIceDEVMODE* pDevMode               - pointer to the BlackIceDEVMODE structure

Return value

Interface Name (string).

Programming Notes

None

Code Example

C# example

 

Please see the following example for IMPORTING the BlackIceDEVMODE.dll, and using GetInterfaceName function in C# code:

 

[DllImport("BlackIceDEVMODE.dll", CharSet = CharSet.Unicode, ExactSpelling = true)]

private static extern IntPtr GetInterfaceName(IntPtr pDevMode);

 

Once imported, one can use the GetInterfaceName function in the C# code as in the following example:

 

//Load BlackIceDEVMODE

IntPtr Devmode = LoadBlackIceDEVMODE("Printer Name");

 

//Call the GetInterfaceName function

IntPtr pInterfaceName = GetInterfaceName(pDevMode);

 

//Get the interface name from unmanaged memory

string interfaceName = Marshal.PtrToStringUni(pInterfaceName);

 

//Release BlackIceDEVMODE

ReleaseBlackIceDEVMODE(Devmode);