Excel VBA 質問スレ Part55at TECH
Excel VBA 質問スレ Part55 - 暇つぶし2ch187:デフォルトの名無しさん
18/08/04 19:58:42.71 FI6ie7QF.net
>>177
こういう処理は関数化した方がよい
Sub test()
  Dim test_string As Variant
  test_string = Array("one", "two", "three")
  If あるかな(test_string, "one") Then
    MsgBox "one" & "はありまーす"
  End If
End Sub
Function あるかな(a, b)
  If InStr(Join(a, "&"), b) Then
    あるかな = True
  Else
    あるかな = False
  End If
End Function


次ページ
続きを表示
1を表示
最新レス表示
レスジャンプ
類似スレ一覧
スレッドの検索
話題のニュース
おまかせリスト
オプション
しおりを挟む
スレッドに書込
スレッドの一覧
暇つぶし2ch