3

使用できます

SelectFolder() でフォルダを取得する

また

ファイルを取得するための GetOpenFolderitem(文字列としてフィルター)

しかし、フォルダまたはファイルのどちらかを選択できますか? (または、複数のファイルを選択することについて)

4

4 に答える 4

5

MonkeyBread プラグインは、OpenDialogMBS クラスでこれを許可します。

http://www.monkeybreadsoftware.net/pluginhelp/navigation-opendialogmbs.shtml

OpenDialogMBS.AllowFolderSelection as Boolean
property, Navigation, MBS Util Plugin (OpenDialog), class OpenDialogMBS, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.

Function: Whether folders can be selected.
Example: 
dim o as OpenDialogMBS
dim i,c as integer
dim f as FolderItem

o=new OpenDialogMBS
o.ShowHiddenFiles=true
o.PromptText="Select one or more files/folders:"
o.MultipleSelection=false
o.ActionButtonLabel="Open files/folders"
o.CancelButtonLabel="no, thanks."
o.WindowTitle="This is a window title."
o.ClientName="Client Name?"
o.AllowFolderSelection=true
o.ShowDialog

c=o.FileCount
if c>0 then
  for i=0 to c-1
    f=o.Files(i)

    FileList.List.AddRow f.AbsolutePath
  next
end if


Notes: 
Default is false.
Setting this to true on Windows or Linux has no effect there.
(Read and Write property)
于 2008-10-04T10:38:36.947 に答える
0

少し遅れましたが、最近のバージョンに含まれています。この質問で誰かが私のようにつまずいた場合に備えて、ここに置きます。

RealBasic の複数選択: OpenDialog.MultiSelect

于 2011-09-09T19:42:38.493 に答える
0

組み込み API を介しては不可能です。それを行うためのプラグインがあるかもしれませんが、それに対する OS サポートはないと思います。

于 2008-09-30T16:21:21.147 に答える
-3

.Net を使用していると仮定すると、独自のコントロールを作成する (または購入する) 必要があると思います。

于 2008-09-19T07:29:28.247 に答える