1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

拡張メソッドの利用

Last updated at Posted at 2013-11-28

拡張メソッドの設定群をまとめて作っておくと結構重宝するので投稿しておく。

StringのIsNullOrEmptyで例を


        <Extension()> _
        Public Function IsNullOrEmpty(ByVal value As String) As Boolean
            Return String.IsNullOrEmpty(value)
        End Function

利用時


dim str as String = "ほげほげほげほげ"

if str.IsNullOrEmpty then
   '値あり!
else
   '値なし!   
end if 

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?