![]() |
![]() |
Aktifkan kembali project Latihan 1
1. Ganti name dari Form1 menjadi frmViewer
2. Pada menu Project, pilih Add Form, kemudian pilih Splash Screen.
Kemudian pada menu Project, pilih Project Properties, dan pilih tab Make
Aturlah properti berikut :
Properti | Value |
Title | Penampil Gambar |
Icon | frmSplash |
Comments | Peringatan : Hak cipta di lindungi Undang-undang |
Company Name | indoprog-vb@yahoogroups.com |
Legal Copyright | Hak Cipta dan Distribusi oleh : |
ProductName | Just4U |
Dan lakukan koding berikut :
Private Sub Form_Load() lblLicenseTo.Caption = "Izin pakai untuk Indoprog-vb" lblPlatform.Caption = "Windows 95/NT" lblVersion.Caption = "Versi" & App.Major & "." & App.Minor & "." & App.Revision lblCompanyProduct.Caption = App.Title lblProductName.Caption = App.ProductName lblCopyright.Caption = App.LegalCopyright lblCompany.Caption = App.CompanyName lblWarning.Caption = App.Comments End Sub
4. Selanjutnya tambahkan sebuah modul, dengan menu Project AddModule, dan lakukan koding berikut :
Public Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Sub Main() frmSplash.Show 'Tampilkan Splash Screen frmSplash.Refresh 'Pastikan Splash Screen ditampilkan sempurna Sleep (1000) 'Berhenti 1 detik frmViewer.Show 'Tampilkan frmViewer Unload frmSplash 'Unload frmSplash End Sub
Pada menu Project, Project Properties, tentukan StartUp Object menjadi SubMain