Random Hadith

Narrated Al-Bara' ibn Azib: I was with Ali (may Allah be pleased with him) when the Apostle of Allah (peace_be_upon_him) appointed him to be the governor of the Yemen. I collected [+] [Abu Dawud 004:1793]

Mutiara Hati

Anda bisa, jika Anda berpikir bisa, selama akal mengatakan bisa. Batasan apakah sesuatu masuk akal atau tidak, kita lihat saja orang lain, jika orang lain telah melakukannya atau telah mencapai impiannya, maka impian tersebut adalah masuk akal

Announcement

 

June 2010
M T W T F S S
« May    
 123456
78910111213
14151617181920
21222324252627
282930  

Archives

Categories

Tags

free counters

Fungsi STOD (Microsoft Visual FoxPro)

Fungsi STOD (String to Date) adalah fungsi buatan sendiri yang bertugas untuk melakukan
konversi data tanggal yang berbentuk string ke bentuk data yang bertype tanggal.

1
2
3
4
5
6
7
8
9
10
11
FUNCTION STOD
LPARAMETERS string_date
LOCAL lc_a
 
SET DATE TO BRITISH
lc_a=string_date
lc_a=IIF(TYPE("lc_a")#"C",DTOS(DATE()),lc_a)
lc_a=IIF(LEN(ALLTRIM(lc_a))<>8,SPACE(8),lc_a)
lc_a=RIGHT(lc_a,2)+"/"+SUBSTR(lc_a,5,2)+"/"+LEFT(lc_a,4)
 
RETURN CTOD(lc_a)

Simpan listing program di atas pada sebuah file sebagai contoh PRCUMUM.PRG
Perhatikan penggunaan fungsi ini

SET PROCEDURE TO PRCUMUM

A=”20081231″
? stod(a)
31/12/2008

dalam Microsoft Visual FoxPro lawan dari fungsi ini adalah fungsi DTOS().

Popularity: 2% [?]

2 comments to Fungsi STOD (Microsoft Visual FoxPro)

Leave a Reply

 

 

 

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">

CommentLuv Enabled
[+] kaskus emoticons nartzco