C#函数在物理地址上的内存 [英] C # function memory on the physical address

查看:79
本文介绍了C#函数在物理地址上的内存的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

  AddressOf  MFS100_OnCodeline 



该函数也是MFS100_OnCodeline的一个函数,也属于parametreleride.很容易完成VB.6.0,但我可以使用C#
完成此操作 感谢您的帮助

解决方案

这不是物理地址

地址不是在托管代码中固定的,因此AdressOf运算符没有任何用途,除了非常特殊的情况,例如与非托管代码互操作.


我认为您需要&操作员.当使用usafe代码时,这将返回某些内容的地址.

&运算符(C#参考) [ ^ ]

这篇堆栈溢出文章还提到了有关内存引用的其他详细信息

http://stackoverflow.com/questions/588817/c-memory-address-and-variable [ ^ ]


AddressOf MFS100_OnCodeline



This function also MFS100_OnCodeline a function are also parametreleride. Is easily done VB.6.0 but I could do this with C #
Thanks for your help

解决方案

It''s not a physical address

Adresses are not fixed in managed code, so there is no purpose for an AdressOf operator, except for very special cases, e.g. interop with unmanaged code.

WHat the heck is a parametreleride?


I think you need the & operator. This returns the address of something when in usafe code.

& Operator (C# Reference)[^]

This stack overflow article also mentions other details regarding memory referencing

http://stackoverflow.com/questions/588817/c-memory-address-and-variable[^]


这篇关于C#函数在物理地址上的内存的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆