In some cases, in order to effectively take platform differences into account, your application will need to execute different code segments on different systems. Operating system and IDL version information is contained in the IDL system variable !VERSION. For example, you could use an IDL CASE statement that looks something like the following to execute code that pertains to a particular operating system family:
!VERSION.OS_FAMILYOF 'unix' : Code for Unix 'Windows' : Code for Windows ENDCASE
Writing conditional IDL code based on platform information should be a last resort, used only if you cannot accomplish the same task in a platform-independent manner.