开发者

Using a variable variable name in Visual Basic

开发者 https://www.devze.com 2023-03-12 07:34 出处:网络
How to use a variable variable name in Visual Basic (.Net)? dim test as String test = \"mysetting\" My.Settings.{test} = \"som开发者_JAVA技巧ething\"

How to use a variable variable name in Visual Basic (.Net)?

dim test as String

test = "mysetting"

My.Settings.{test} = "som开发者_JAVA技巧ething"

Which should be the same as doing:

My.Settings.mysetting = "something"


Eh?

My.Settings(test) = "something"
0

精彩评论

暂无评论...
验证码 换一张
取 消