GetOpenFilename that works with Windoze old and new


File browsing from the Notes client is easier with R5's new "OpenFileDialog" NotesUIWorkspace method, but what about backwards compatibility (with Win95 etc.) within a newer (XP / Professional) Windows environment?

An application I look after recently got upgraded to an R5 server, but had to work with R4.x clients on Win95 and R5 clients on Win2k. It used a Win32 function adapted for Lotusscript, that browsed the local file system (i.e. used a common dialog box).

This code no longer worked in R5, despite it making use of a standard Win32 call. After a lot of head-scratching I figured out why (and will update this document to tell you once I read the code again / remember), and I was able to sort it out so that it worked again, in both environments.

Download the attached LSS file, and do with it what you will (I suggest creating a blank script library, and then doing a File / Import with the LSS file).

Further reading


Comments on this post are now closed.


I’m a software architect / developer / general IT wrangler specialising in web, mobile web and middleware using things like node.js, Java, C#, PHP, HTML5 and more.

Best described as a simpleton, but kindly. You can read more here.

File Attachment Icon