Replacement for TypeLibFunc in .NET Standard

229 views Asked by At

I'm trying to uplift some older .NET Framework code to .NET Standard 2.0.

[TypeLibFunc(TypeLibFuncFlags.FRestricted)]
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType=MethodCodeType.Runtime)]
void InitNew([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)] byte[] _rgb, int cb);

TypeLibFunc doesn't exist here. Is it still valid, and is there a replacement/substitute for it? I see a TYPEFLAGS enum but don't see a way to apply it. I would like to avoid Std 2.1, as it loses compatibility with Framework.

0

There are 0 answers