slide in Label

  • Thread starter Thread starter Pieter
  • Start date Start date
P

Pieter

Hi,

For status messages ("succesfully saved", "item added", ...) I want a label
that slides in on the moment there is a message, shows the message for 5
seconds, and than slides away again.

I googled for it, but didn't find anything usefull.

Anybody has any idea? Some sample code? I'm using VB.NET 2005.

Thanks,

Pieter
 
Hi Pieter,

I am always confused not to see DragoVasu and think than who is that Pieter.

Peter Proost, Pieter Coucke, why is it that I have always to think about
beer by that.

However, in my opinion is this something as done when you do not use marquee
on a webpage (because you want it variable). Just a timer and set the text
in the label using an substring that you let go using an index.

I think that in VB is the static keyword is very nice for that inside the
timer for the index.

I assume that you understand this and that no sample is needed.

:-)

Cor
 
Hehe I do understand it, and I would indeed do it with a timer. But it seemd
something that people must have wanted before, and I was hoping that
somebody could give me the whole code, hehe :-) I don't like re-inventing
the wheel :-)

About the Peter Proost-stuff: We actually do say "proost" before we drink a
beer :-) Something like "scholl" or "santé" or "gezondheid" :-)

Pieter
 
Pieter,
About the Peter Proost-stuff: We actually do say "proost" before we drink
a beer :-) Something like "scholl" or "santé" or "gezondheid" :-)

Curious that we use in my native language as well.

:-)

Cor
 
Pieter,

I think that it is not more than 10 lines of code.

Your only problem is to find if the index plus the lenght of the text is not
longer than the string, and than connect the first part again with a space
and the length that stays.

(Or do it in any other marquee style way).

Cor
 
You can easily move controls about and in VB.NET 2005 you also have the new
capabilities of the tooltip which can be positioned anywhere.

Perhaps you could coerce that?


--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.
 
Back
Top