LoadDS Example for Delphi
var
nRet: Integer;
begin
{ load a Data Set }
LEADDicom1.EnableMethodErrors := false;
LEADDialog1.UIFlags := DLG_FO_SHOWPREVIEW or DLG_FO_SHOWSTAMP;
LEADDialog1.Filter := 'DICOM Files|*.dic';
nRet := LEADDialog1.FileOpen(self);
If nRet = SUCCESS Then
nRet := LEADDicom1.LoadDS(LEADDialog1.filename, 0);
If (nRet <> SUCCESS) and (nRet <> ERROR_DLG_CANCELED) Then
ShowMessage('Error ' + IntToStr(nRet) + ' loading file!');
LEADDicom1.EnableMethodErrors := true;
end;