Jumat, 28 Desember 2012

[belajar-access] Scrolling text pada status bar

 

assalamu'alaikum Wr. Wb.

maaf, mau tanya tentang scroling text

setelah googling akhirnya nemu code (seperti dibawah) untuk scroling
text, nah yang jadi pertanyaan. ketika formnya ditutup, pinginnya
untuk scrol text yang ada di status bar tetap berjalan, kira-kira
modifikasinya seperti apa (agar tidak mneggunakan form timer)

ini VBA nya

Option Compare Database
Option Explicit

Public txtScrollStatus As String ' Needed for Status Bar

Private Sub Form_Load()
' Text for Caption of Form
Me.Caption = DLookup("[ket]", "qryFormCaption")

' Text for Label on Form
Me.lblScrollingLabel.Caption = "Scrolling Text ......................... "

' Text for Status Bar
txtScrollStatus = "Scrolling Text ......................... "

End Sub

' Special Note ...........
' Set Form's Timer Interval to 100
Private Sub Form_Timer()

' Produce the Scrolling Text in Caption on the Form
Me.Caption = Mid(Me.Caption, 2, _
(Len(Me.Caption) - 1)) & Left(Me.Caption, 1)

' Produce the Scrolling Text in Label on the Form
Me.lblScrollingLabel.Caption = Mid(Me.lblScrollingLabel.Caption, 2, _
(Len(Me.lblScrollingLabel.Caption) - 1)) &
Left(Me.lblScrollingLabel.Caption, 1)

' Produce the Scrolling Text in Status Bar of Access
SysCmd acSysCmdSetStatus, txtScrollStatus
txtScrollStatus = Mid(txtScrollStatus, 2, (Len(txtScrollStatus) - 1))
& Left(txtScrollStatus, 1)

End Sub

__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)
Recent Activity:
SPAM IS PROHIBITED
.

__,_._,___

Tidak ada komentar:

Posting Komentar