Показать сообщение отдельно
  #12  
Старый 06.03.2013, 10:35
Аватар для NumLock
NumLock NumLock вне форума
Let Me Show You
 
Регистрация: 30.04.2010
Адрес: Северодвинск
Сообщения: 5,426
Версия Delphi: 7, XE5
Репутация: 59586
По умолчанию

все честно:
Код:
unit Unit1;

interface

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

type
  TForm1 = class(TForm)
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

Function iif(cond:Boolean;vt,vf:String):String; overload;
Function iif(cond:Boolean;vt,vf:Integer):Integer; overload;

implementation

{$R *.dfm}

Function iif(cond:Boolean;vt,vf:String):String;
Begin
 if cond then Result := vt else Result := vf;
End;

Function iif(cond:Boolean;vt,vf:Integer):Integer;
Begin
 if cond then Result := vt else Result := vf;
End;

end.
__________________
Пишу программы за еду.
__________________
Ответить с цитированием