|
From: Frazier, J. J. <Joe...@Pe...> - 2001-09-26 13:12:23
|
Tested:
use Win32::FileOp;
my @filenames =3D Win32::FileOp::OpenDialog(
title =3D> 'Test',
filters =3D> [ 'Word Documents' =3D> '*.rtf;*.doc', 'All' =3D> =
'*.*'],
defaultfilter =3D> 1,
dir =3D> 'c:\\',
filename =3D> ' ',
handle =3D> 0,
options =3D> OFN_ALLOWMULTISELECT | OFN_EXPLORER, # does multi
select and does explorer type interface
);
print join("\n", @filenames);
Aldo, any chance of getting the bit flags in the options added to the
Win32::GUI::GetOpenFileName function so that it allows multiple files?
I dont know what these consants are named in Windows, but here are the
values from the Win32::FileOp module:
OFN_ALLOWMULTISELECT =3D> 512
OFN_EXPLORER =3D> 524288
I tried [addstyle|style] to set these, but that did not work. If we can
get this to work with SendMessage, or any other way, let us know. =20
-----Original Message-----
From: Marcus [mailto:li...@wo...]
Sent: Wednesday, September 26, 2001 1:19 AM
To: per...@li...
Subject: [perl-win32-gui-users] Selecting multiple files
It doesn't seem that you can select more than one file with
GetOpenFileName. Is that correct?
I tried using Win32::FileOp::OpenDialog, but get the following error:
Can't locate auto/DELETE.al in @INC(...) at ...Win32/FileOp.pm line
941.
Here is the code:
sub ::AddFilesButton_Click { defined(my $root =3D
$Win32::GUI::Loft::window{MyWindow}) or return(1);
use Win32;
use Win32::FileOp;
my @filenames =3D $root->Win32::FileOp::OpenDialog(
-options =3D> 'OFN_ALLOWMULTISELECT');
...
Thanks for any help,
Marcus
_______________________________________________
Perl-Win32-GUI-Users mailing list
Per...@li...
https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users
|