Filesavedialog() Not Showing Files According To Filter, "save As Type" Has Strange Entries


gkimsey

Recommended Posts

I have a pretty straightforward File Save Dialog in a quick sequence. Code looks like this:

private string fileName = file.FileSaveDialog(g_log_filename,"","*.csv","CSV Files")[/CODE]

where g_log_filename is an existing global string containing the full path to a CSV file.

But when the dialog comes up I don't see existing files with the CSV extension in the directories I'm working through. I thought the filter might be wrong, but "*.csv" is exactly what tooltip example has in it. How do I fix this?

Also, at the bottom of the dialog where you can choose "Save as type..." from a dropdown, there is usually some random text from one of my scripts stuck in there somehow. I'm guessing the FileSaveDialog doesn't actually use the Save As Type, but it'd be better if it only showed *.csv.

See attached screenshot. OS is Windows 7.

post-8957-0-04840800-1372785100_thumb.pn

Link to comment
Share on other sites

Windows is a little messed up here. To get it to display *.csv you have to put *.csv in the first parameter. The weird display also appears to be some sort of Windows glitch. It does it in Windows 8 too. We'll take a closer look.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.