Prayer Time Library

Prayer time library for calculate time

how to use

parameter latitude and longitude and timezone and Height for location

example jakarta
latitude = -6.21522
longitude = 106.818
timezone = +7
Height =100

delphi or lazarus :

TTime = record
 imsyak, shubuh, sunset, dzuhur, ashar, maghrib, isya: extended;
 end;

function calctime(latitude, longitude: extended; timezone, Height: integer;
 tanggal: TDate): TTime; stdcall; external 'STime.dll';

procedure TForm1.Button1Click(Sender: TObject);
 var
 calc: TTime;
 begin
 calc := calctime(-6.21522, 106.818, 7, 100, now);
 Memo1.Lines.Add('imsyak ' + FormatDateTime('hh:mm:ss', calc.imsyak));
 Memo1.Lines.Add('shubuh ' + FormatDateTime('hh:mm:ss', calc.shubuh));
 Memo1.Lines.Add('sunset ' + FormatDateTime('hh:mm:ss', calc.sunset));
 Memo1.Lines.Add('dzuhur ' + FormatDateTime('hh:mm:ss', calc.dzuhur));
 Memo1.Lines.Add('ashar ' + FormatDateTime('hh:mm:ss', calc.ashar));
 Memo1.Lines.Add('maghrib ' + FormatDateTime('hh:mm:ss', calc.maghrib));
 Memo1.Lines.Add('isya ' + FormatDateTime('hh:mm:ss', calc.isya));
 end;

Download

reference Algorithm:
prayer time algorithm

Advertisements
This entry was posted in C\C++, Delphi, Freepascal, Lazarus, Pascal, Programming, Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s