|
-
May 27th, 2026, 02:01 AM
#1
Thread Starter
PowerPoster
FLASHING image
how to flashing two image ?
attached the image
alternate the two color image:
yellow
red
yellow
red
ecc...
Last edited by luca90; May 27th, 2026 at 02:23 AM.
-
May 27th, 2026, 05:39 AM
#2
Re: FLASHING image
Timer and 2 picture boxes?
-
May 27th, 2026, 06:22 AM
#3
Re: FLASHING image
 Originally Posted by Arnoutdv
Timer and 2 picture boxes?
Timer and 1 PictureBox, but 2 BitMaps.
Just Load alternate BitMap on Timer-Event, or load both into Memory, and then just assign on Timer-Event
Probably needs Repainting/Refresh, too.
If it's really just those small squares, a Label might be an Option.
No Caption, Autosize=False, Background opaque, and then just set Background-Color on Timer-Event
Last edited by Zvoni; Tomorrow at 31:69 PM.
----------------------------------------------------------------------------------------
One System to rule them all, One Code to find them,
One IDE to bring them all, and to the Framework bind them,
in the Land of Redmond, where the Windows lie
---------------------------------------------------------------------------------
People call me crazy because i'm jumping out of perfectly fine airplanes.
---------------------------------------------------------------------------------
Code is like a joke: If you have to explain it, it's bad
-
May 27th, 2026, 08:17 AM
#4
Thread Starter
PowerPoster
Re: FLASHING image
 Originally Posted by Zvoni
Timer and 1 PictureBox, but 2 BitMaps.
Just Load alternate BitMap on Timer-Event, or load both into Memory, and then just assign on Timer-Event
Probably needs Repainting/Refresh, too.
If it's really just those small squares, a Label might be an Option.
No Caption, Autosize=False, Background opaque, and then just set Background-Color on Timer-Event
I think not is for me..E.
can you post an example.?
tks
-
May 27th, 2026, 10:23 AM
#5
Re: FLASHING image
Ask AI.
Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.
-
May 27th, 2026, 11:43 AM
#6
Member
Re: FLASHING image
I that the job now, "Ask AI" when we know AI makes too many mustkes. Quote from AI. lol
-
May 27th, 2026, 03:42 PM
#7
Re: FLASHING image
Use a Shape, FillStyle = 0 (solid). Change the FillColor with a timer.
-
May 27th, 2026, 09:15 PM
#8
Re: FLASHING image
what Arnoutdv wrote. this is where u start. u use what VB offers. its simple. its intuitive. its learning exercise.
later when you ready, u will be ready for more.
if u can't even use the common component of VB u should just quit trying. this after 20+ years.
-
May 28th, 2026, 01:05 AM
#9
Re: FLASHING image
 Originally Posted by Eduardo-
Use a Shape, FillStyle = 0 (solid). Change the FillColor with a timer.
Nice.
For some unfathomable reason, i always forget the Shape-Control.
Probably because i never used it
Last edited by Zvoni; Tomorrow at 31:69 PM.
----------------------------------------------------------------------------------------
One System to rule them all, One Code to find them,
One IDE to bring them all, and to the Framework bind them,
in the Land of Redmond, where the Windows lie
---------------------------------------------------------------------------------
People call me crazy because i'm jumping out of perfectly fine airplanes.
---------------------------------------------------------------------------------
Code is like a joke: If you have to explain it, it's bad
-
May 28th, 2026, 03:02 AM
#10
Thread Starter
PowerPoster
Re: FLASHING image
 Originally Posted by zvoni
nice.
For some unfathomable reason, i always forget the shape-control.
Probably because i never used it
infact never used
-
May 28th, 2026, 03:12 AM
#11
Re: FLASHING image
shape is good, but not as good as a picturebox.
shape has the same issue like an image object, they can flicker.
even so, to realize that, u need to try it. thats when u see the good and the bad.
thats when u evolve and start looking for something that can fix the limitations.
-
May 28th, 2026, 11:27 AM
#12
-
May 29th, 2026, 12:45 AM
#13
Re: FLASHING image
nothing fancy...
2x Shape
1x Timer
set your timer Interval as you need it
Code:
Private Sub Form_Load()
Shape1.FillStyle = 0
Shape1.Height = 330
Shape1.Left = 2415
Shape1.Top = 1995
Shape1.FillColor = vbYellow
Shape2.FillStyle = 0
Shape2.Height = 330
Shape2.Left = 2415
Shape2.Top = 1995
Shape2.FillColor = vbRed
Timer1_Timer
End Sub
Private Sub Timer1_Timer()
Shape2.Visible = Not Shape2.Visible
End Sub
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
-
May 29th, 2026, 01:00 AM
#14
Re: FLASHING image
Alternative to Chris with 1 Shape
Untested
Code:
Private col(0 To 1) As Long
Private Sub Form_Load()
col(0) = vbYellow
col(1) = vbRed
Shape1.FillStyle = 0
'Where's "Width"? :)
Shape1.Height = 330
Shape1.Left = 2415
Shape1.Top = 1995
Shape1.FillColor = col(0)
Timer1_Timer
End Sub
Private Sub Timer1_Timer()
Static a As Long
If a = 0 Then a = 1 Else a = 0
Shape1.FillColor = col(a)
End Sub
Last edited by Zvoni; Tomorrow at 31:69 PM.
----------------------------------------------------------------------------------------
One System to rule them all, One Code to find them,
One IDE to bring them all, and to the Framework bind them,
in the Land of Redmond, where the Windows lie
---------------------------------------------------------------------------------
People call me crazy because i'm jumping out of perfectly fine airplanes.
---------------------------------------------------------------------------------
Code is like a joke: If you have to explain it, it's bad
-
May 29th, 2026, 02:01 AM
#15
Thread Starter
PowerPoster
Re: FLASHING image
 Originally Posted by ChrisE
nothing fancy...
2x Shape
1x Timer
set your timer Interval as you need it
Code:
Private Sub Form_Load()
Shape1.FillStyle = 0
Shape1.Height = 330
Shape1.Left = 2415
Shape1.Top = 1995
Shape1.FillColor = vbYellow
Shape2.FillStyle = 0
Shape2.Height = 330
Shape2.Left = 2415
Shape2.Top = 1995
Shape2.FillColor = vbRed
Timer1_Timer
End Sub
Private Sub Timer1_Timer()
Shape2.Visible = Not Shape2.Visible
End Sub
GREAT CODE!!!!
tested and work perfect
tks bro!
-
May 29th, 2026, 02:02 AM
#16
Thread Starter
PowerPoster
Re: FLASHING image
 Originally Posted by Zvoni
Alternative to Chris with 1 Shape
Untested
Code:
Private col(0 To 1) As Long
Private Sub Form_Load()
col(0) = vbYellow
col(1) = vbRed
Shape1.FillStyle = 0
'Where's "Width"? :)
Shape1.Height = 330
Shape1.Left = 2415
Shape1.Top = 1995
Shape1.FillColor = col(0)
Timer1_Timer
End Sub
Private Sub Timer1_Timer()
Static a As Long
If a = 0 Then a = 1 Else a = 0
Shape1.FillColor = col(a)
End Sub
GREAT CODE!!!!
tested and work perfect
tks bro!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|