More on 'Save As'
- Posted by guest at rapideuphoria.com Feb 12, 2004
- 557 views
posted by: a.admin at myway.it Sorry for a mistake of mine: >I realized that the system does never select the proper file list to show in >the dialog box .. is not true: the system requires the exact and clean format '*.ext' to display files. the code: ---------- -- and user canceled, this would still run! if compare( filters, ".*" ) = 1 then -- only if an .ext is declared, not '.*' if filters[1] = 46 then -- '.' the dot fName = fName&filters else fName = fName&"."&filters -- may be useful, or ignored end if end if end if ---------- should be adapted to: ---------- if compare(filters,"*.*") = 1 then -- only if an .ext is declared filters = filters[2..length(filters)] if filters[1] = 46 then -- '.' the dot fName = fName&filters else fName = fName&"."&filters -- may be ignored end if end if end if ---------- But it is not performed however a real OFN_OVERWRITEPROMPT check on the file, saving it after a warning referred to the name (not the extension) and then with a filename.ext probably unespected by the Windows user. As a matter of fact, the dialog box says: "Save as Type: " followed by the definition selected by the user, like "Text File", or "Euphoria Program" etc.. Hope in a true solution for that. Thanks.