什么是“VB.NET我的”相当于C#? [英] What is "VB.NET My" equivalent in C#?

查看:75
本文介绍了什么是“VB.NET我的”相当于C#?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




在VB.NET中有一个名为My的关键字。它有很多属性

收集它。


有没有相当于这个我的在C#中?


谢谢。

Hi,

In VB.NET there is a keyword called "My" which has a lot of properties
collected at it.

Is there any equivalent to this "My" in C#?

Thank you.

推荐答案

" this是用于访问代码从中调用的类或结构的关键字。同样的规则适用,因为如果它是实例成员(不是静态的(在VB中共享),你只能向对象引用

。)


Bishoy写道:
"this" is the keyword used to access the class or struct that the code is
being called from. The same rules apply, in that you can only make references
to the object if it is an instance member (not static (Shared in VB)).

"Bishoy" wrote:




在VB.NET中有一个名为我的的关键字。它有很多属性

收集它。


有没有相当于这个我的在C#中?


谢谢。
Hi,

In VB.NET there is a keyword called "My" which has a lot of properties
collected at it.

Is there any equivalent to this "My" in C#?

Thank you.


Mr Icekirby写道:
Mr Icekirby wrote:

" this"是用于访问代码从中调用的类或结构的关键字。同样的规则适用,因为如果对象是实例成员(非静态(在VB中共享)),则只能对对象进行引用


"this" is the keyword used to access the class or struct that the code is
being called from. The same rules apply, in that you can only make references
to the object if it is an instance member (not static (Shared in VB)).



你困惑我和我。我==这个。但是,在c#中没有相当于My的
。它只是VB 2005的一部分。

You are confusing Me and My. Me == this. However, there is no
equivalent to My in c#. It''s a VB 2005 only thing.


>

" Bishoy"写道:
>
"Bishoy" wrote:

>

在VB.NET中有一个名为我的的关键字。它收集了很多属性。

有没有相当于这个我的在C#中?

谢谢。
>Hi,

In VB.NET there is a keyword called "My" which has a lot of properties
collected at it.

Is there any equivalent to this "My" in C#?

Thank you.


Mr Icekirby写道:
Mr Icekirby wrote:

" this"是用于访问代码从中调用的类或结构的关键字。同样的规则适用,因为如果它是一个实例成员(不是静态的(在VB中共享

),你只能对该对象进行

引用)。


" Bishoy"写道:
"this" is the keyword used to access the class or struct that the code is
being called from. The same rules apply, in that you can only make
references to the object if it is an instance member (not static (Shared
in VB)).

"Bishoy" wrote:

>

在VB.NET中有一个名为我的的关键字。它收集了很多属性。

有没有相当于这个我的在C#中?

谢谢。
>Hi,

In VB.NET there is a keyword called "My" which has a lot of properties
collected at it.

Is there any equivalent to this "My" in C#?

Thank you.



不幸的是,我的与this不同。在VB .NET中,它实际上是我。这相当于this。


" My"不能直接在C#中使用。


-

希望这会有所帮助,

Tom Spink

谷歌首先,稍后再询问。

Unfortunately, "My" is not the same as "this". In VB .NET it''s
actually "Me" that is the equivalent to "this".

"My" is not available in C# directly.

--
Hope this helps,
Tom Spink

Google first, ask later.


这篇关于什么是“VB.NET我的”相当于C#?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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