Look at some of the examples that ship with LabView like Write Datalog File Example.vi. To find the example, from any LabView window goto Help >> Find Examples >> Search and enter "datalog" in the box labeled Type a keyword to find:
If you don't want to use datalog files, you can open a file with the Open/Create/Replace File function from the File I/O palette. If you don't wire the file path input, a dialog pops up to select or enter a file name.