There is a small error in MSDN (which is presumably where you got that from). You can't have a space in the string, so it should be
VB Code:
  1. File1.Pattern = "*.jpg;*.bmp"