See the
CFileDialog documentation[
^]. There are several useful code examples.
In your code, the filter is fine, but the second and third parameters don't fit: these should be the extension of the file to be selected (e. g. ".pdf"), and the default name of the file to be opened (e. g. "mytext.pdf"). Setting the file path requires a modification of the ofn structure: the first code example in the documentation shows how this is done.
As for the dialog buttons, these are always called [Ok] and [Cancel]. That [Ok] means "Open" should be obvious because the dialog title says "open" already. It would be unwise to try and change the dialog captions, since everyone used to Windows will understand how it works, and might be confused if your dialog looks different.