I want the file selction dialog to be popping up when i press a button.For this i am using org.eclipse.swt.widgets.FileDialog class and opening the dialog. By default there are two buttons "Open"(the button we press after selecting the file) and "Cancel" button.
I want the name on the button to change from "Open" to "Import".
Is it possible to override this button on FileDialog?
SWT uses OS resources. The file dialog you see is the typical OS dialog for opening files. You can't change the button's text without implementing your own dialog.
The only alternative to Open
is Save
by using the style bit:
SWT.SAVE
instead of
SWT.OPEN
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.