How can I call an Assembly procedure from C# and get a result back?
I’m trying to call a very simple Assembly procedure from C# to get something returned from it. Here’s the C# code: class Program { static void Main(string[] args) { ulong test = Start(); Console.WriteLine(test); } [DllImport(@"C:\dev\masm\basic.dll")] private static extern ulong Start(); } Here’s the Assembly (MASM) code: .code Start proc mov rax, 1 ret Start… Read More How can I call an Assembly procedure from C# and get a result back?