15-10-2008, 07:56 PM
Bocaloca Wrote:Als Excel open is druk je op Alt+F11 nu kom je in de "Visual Basic Editor"
Klik rechts op "Vbproject(Map1)" en kies Invoegen - Module
Rechts zie je Option Explicit met de cursor,
de code hieronder kopieer je en plak je in dit vak.
Ga nu naar Extra - Macro - Macro's en kies Knipper
Sla het bestand op.
Sub Knipper()
Dim interval As Date, myCell As Range
Set myCell = Worksheets(1).Range("A1")
interval = TimeValue("00:00:02")
knip = Not knip
tel = tel + 1
If tel = 10 Then
myCell.Interior.Color = 0
Exit Sub
End If
myCell.Interior.Color = IIf(knip, RGB(256, 0, 0), RGB(0, 256, 0))
Application.OnTime Now + interval, "Knipper"
End Sub
Cel A1 zal nu knipperen
NERD! NERD! NERD! :
She was only the Gardener's daughter, but boy! What a melons!