VBScript のプロパティ、Pattern プロパティ ?
Set r = New RegExp str = "abc" r.Pattern = "ab?" Set Matches = r.Execute(str) MsgBox Matches(0) ' ab str = "abc" r.Pattern = "ac?" Set Matches = r.Execute(str) MsgBox Matches(0) ' a str = "abbbc" r.Pattern = "ab?" Set Matches = r.Execute(str) MsgBox Matches(0) ' ab