Forum > Windows (32/64)
Dialogs and Windows PE
atasoft:
--- Quote from: atasoft on March 05, 2024, 12:08:41 pm ---Thank you very much Bart. TOpenDialog and TSaveDialog is working on Windows PE changing the options to old style dialog. TSelectDirectoryDialog does NOT work.
Solution:
procedure TMainForm.btnSaveDlgClick(Sender: TObject);
var
FileName: String;
sd: TSaveDialog;
begin
sd := TSaveDialog.Create(Self);
sd.Options := [ofOldStyleDialog]; // Set old style dialog to avoid Access Violation under Windows PE
try
if not sd.Execute then Exit; // Access Violation under Windows PE
FileName:=sd.FileName;
edtPath.Text:=FileName;
finally
sd.Free;
end;
end;
--- End quote ---
The above solution works but I can not resize the dialog although I set ofEnableSizing in Options.
My problem is the small width of dialog components (Editbox and ListBox).
Is there a solution or do I have to create my own dialog?
d2010:
--- Quote from: atasoft on March 05, 2024, 08:43:06 am ---Hi,
I am trying to write a program to select disk drive and path.
--- End quote ---
C:A1=I understand in Win_XP Live .iso, this code line , bellow not exist:
--- Code: --- SHGetPathFromIDList(PItemIDList(lParam), @PathName);
--- End code ---
because only WinVista+ have got the " SHGetPathFromIDList"
Navigation
[0] Message Index
[*] Previous page