Pls everyone, i need help with two regula expressions

One to accept only file word and pdf file and the other to accept only images(.jg|.bmp|.png|.gif)


Do you want to "open" only word, pdf or image files ??? for that you should use "OpenFileDialog" with "Filter" property to:


Here is the combine "pattern":


here is the pattern for first condition:


here is the pattern for second condition: