Announcement

Collapse
No announcement yet.

%OFN_EXPLORER

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • %OFN_EXPLORER

    Could any of you give me an example using the fileopen dialog with style set to
    %OFN_ALLOWMULTISELCET and %OFN_EXPLORER in a way that I can retrieve the filenames
    including the path.

    I am getting only the path nothing else when I select more than one file.


    ------------------

  • #3
    Thank you Borje,
    Your hind's helped me to solve my problems gettig the filenames from the OpenFileDialog when using the %OFN_EXPLORER style.

    I modified the COMDLG32.INC a little so that both OpenFileDialogs can be used ...

    '-----------------------------------------------------------------------------------------------
    FUNCTION OpenFileDialog (BYVAL hWnd AS LONG, _ ' parent window
    BYVAL Caption AS STRING, _ ' caption
    Filespec AS STRING, _ ' filename -> genaue Form beachten
    BYVAL InitialDir AS STRING, _ ' start directory -> optional
    BYVAL Filter AS STRING, _ ' filename filter
    BYVAL DefExtension AS STRING, _ ' default extension
    Flags AS DWORD _ ' flags
    ) AS LONG


    LOCAL Ofn AS OPENFILENAME
    LOCAL zFile AS STRING*10240

    IF %OFN_EXPLORER=%TRUE THEN zFile=zFile+CHR$(0) ' <- that did it

    LOCAL zFileTitle AS ASCIIZ * 256
    LOCAL zFilter AS ASCIIZ * 256
    LOCAL zInitialDir AS ASCIIZ * 256
    LOCAL zTitle AS ASCIIZ * 256
    LOCAL zDefExt AS ASCIIZ * 256

    other code (not modified)

    I found out that the other corrections, you made, are not necessary. Tested under NT and WIN98.

    Regards,
    Heinz

    ------------------

    Comment

    Working...
    X