unit ProductProp;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, ProdFrame;

type
  TProductPropForm = class(TForm)
    frmProd1: TfrmProd;
    procedure FormClose(Sender: TObject; var Action: TCloseAction);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

  procedure ShowProductPropForm(idobj, objname: string);

var
  ProductPropForm: TProductPropForm;

implementation

{$R *.dfm}

procedure ShowProductPropForm(idobj, objname: string);
var
  w: TProductPropForm;
begin
  w := TProductPropForm.Create(nil);
  try
    w.frmProd1.FetchData(idobj, objname);
    w.ShowModal;
  finally
    w.Free;
  end;
end;

procedure TProductPropForm.FormClose(Sender: TObject;
  var Action: TCloseAction);
begin
  if frmProd1.Memo.Modified then frmProd1.SaveInfo;
end;

end.
