Solved

Optional Parameter

Posted on 2001-09-03
3
167 Views
Last Modified: 2010-04-06
I want to pass a optiponal paramenter in a function as date.
0
Comment
Question by:princemahesh
3 Comments
 
LVL 7

Accepted Solution

by:
Motaz earned 20 total points
ID: 6452244
function Add(X: Integer; ADate: TDateTime = 0): Integer;
begin
  ShowMessage(IntToStr(X));
  ShowMessage(DateToStr(ADate));
  Result:= Trunc(ADate);
end;
0
 

Expert Comment

by:DelFreak
ID: 6452263
Listening...
0
 

Author Comment

by:princemahesh
ID: 6452267
Thanks,

I was tring to set default value to Null instead of '0'.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now