VBScript のプロパティ、Pattern プロパティ *
Set r = New RegExp str = "abc" r.Pattern = "ac*b" Set Matches = r.Execute(str) MsgBox Matches.Count ' 1 MsgBox Matches(0) ' ab str = "abc" r.Pattern = "acb" Set Matches = r.Execute(str) MsgBox Matches.Count ' 0
Set r = New RegExp str = "abc" r.Pattern = "ac*b" Set Matches = r.Execute(str) MsgBox Matches.Count ' 1 MsgBox Matches(0) ' ab str = "abc" r.Pattern = "acb" Set Matches = r.Execute(str) MsgBox Matches.Count ' 0