Arsip: Format Date tanpa merubah regiional setting
more 15 years ago
delphi_warrior
Hi guys...
ada cara gak utk format date, spy berlaku untuk semua komponen di aplikasi kita...ky datetimepicker, datetostr, dll
aku udah coba pk GetLocaleFormatSettings, tp hanya berlaku utk perintah datetostr aja, sedang utk komponen macam datetimepicker tdk berlaku..
kalo di VFP kan gampang misal tinggal set date ital, mk semua yg berhubungan dgn date akan mengikuti format tsb...
Trims
more 15 years ago
ImanD
@delphi_warior
coba jump kesini sapa tau lebih terbuka lagi http://pascal-id.org/thread/unknown/4510/view-old-thread/
more 15 years ago
herux
hati2 kalo jump-jump. kalo kejauhan bisa nyampai maroko.!! dah beda lagi setting regionalnya !
wakakakk...
more 15 years ago
delphi_warrior
@mas_kofa & @ImanD
ShortDateFormat & LongDateFormat kan utk convert sblm dimasukkan ke DB, atau utk showmessage aja
maksud sy...agar datetimepicker nya udah langsung ngikuting format date yg kita inginkan itu gimana? selain ngrubah regional settingnya...
Trims
more 15 years ago
asiyrob
sepengetahuan saya:
ga' bisa ngubah format di DateTimePicker selain dari CPanel regional setting..
Description
If DateFormat is set to dfShort, the date is formatted using the short date format specified in the Windows control panel. By default, it appears like this: 3/21/97.
If DateFormat is set to dfLong, the date is formatted using the long date format specified in the Windows control panel. By default, it appears like this: Friday, March 21, 1997. (Applies only when Kind is dtkDate.)
For custom date formats, set the Format property.
more 15 years ago
ImanD
@delphi_warrior: @mas_kofa & @ImanD ShortDateFormat & LongDateFormat kan utk convert sblm dimasukkan ke DB, atau utk showmessage aja maksud sy...agar datetimepicker nya udah langsung ngikuting format date yg kita inginkan itu gimana? selain ngrubah regional settingnya... Trimssebenernya saya ga terlalu mengerti maksud @delphi_warrior, ya wis lah saya titik beratkan di BOLD az keh dan kurang setuju dengan pernyataan @asiyrob ini mungkin sample yg akan saya tunjukan u/ merubah TDateTimePicker Format (mudah2an maksudnya bener sesuai yg di harapkan)
uses
COMMCTRL;
procedure TForm1.FormShow(Sender: TObject);
begin
DateTime_SetFormat(DateTimePicker1.Handle, PChar('yyyy/MM/dd')); // atw mo di ganti jadi 'dd/MM/yyyy' or what ever lah, xixixi
end;
more 15 years ago
elva_ivana
@delphi_warrior
klo sy gak salah tagkep, mungkin maksud nya ada di http://www.geocities.com/elva_ivana/reg_setting.html
Semoga membantu
more 15 years ago
delphi_warrior
Trims All
terutama @elva_ivana...memang benar itu yg sy maksud...
ternyata sy salah meletakkan posisi perubahan global variable nya
sekali trims
more ...
- Pages:
- 1
reply |
Report Obsolete
Last Articles
Last Topic
- PascalTalk #6: (Podcast) Kuliah IT di luar negeri, susah gak sih?
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #5: UX: Research, Design and Engineer
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #4: Obrolan Ringan Seputar IT
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #2: Membuat Sendiri SMART HOME
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #3: RADically Fast and Easy Mobile Apps Development with Delphi
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #1: Pemanfaatan Artificial Intelligence di Masa Covid-19
by LuriDarmawan in Tutorial & Community Project more 4 years ago - Tempat Latihan Posting
by LuriDarmawan in OOT more 4 years ago - Archive
- Looping lagi...
by idhiel in Hal umum tentang Pascal Indonesia more 12 years ago - [ask] koneksi ke ODBC user Dsn saat runtime dengan ado
by halimanh in FireBird more 12 years ago - Validasi menggunakan data tanggal
by mas_kofa in Hal umum tentang Pascal Indonesia more 12 years ago
Random Topic
- transfer waktu ke SQL
by coacoac in Tip n Trik Pemrograman more 17 years ago - Huruf Arab
by armanefendi in Tip n Trik Pemrograman more 17 years ago - Selain Delphi...???
by ZeAL in OOT more 19 years ago - Baca File CSV(Comma Seperated Value) melalui delphi
by kacungdelphi24 in Tip n Trik Pemrograman more 16 years ago - klik cell di dbgrid
by dauf in Tip n Trik Pemrograman more 17 years ago - Tanya cara nampilin data di combobox
by dauf in Tip n Trik Pemrograman more 17 years ago - [Ask] Gimana extract setiap warna ke array
by derim in Form Enhancement & Graphical Controls more 15 years ago - Bagaimana caranya bisa Otomatis turun kebawah
by javaman in Hal umum tentang Pascal Indonesia more 18 years ago - Mencari Pegawai Pensiun
by oshea in Tip n Trik Pemrograman more 12 years ago - bikin folder baru
by lela in Tip n Trik Pemrograman more 18 years ago