CanOz Blog

Neil Knobbe's Blog at vbCity

vbCity Blogs moved to:
http://cs.vbcity.com/blogs
  Home :: Syndication  :: Login

OctNovember 2009Dec
SMTWTFS
25262728293031
1234567
891011121314
15161718192021
22232425262728
293012345

Archives

Image Galleries

vbCity Blogs

Ok, let’s call this page 22,492 in the book of things I did not know about Visual Studio 2005.

I was reading something the other day, if I can remember or find it I will post up a link, and was surprised that I had missed this little bit before. 

(I have recently been reading “WPF for those who know Windows Forms” that can be found here  and watching webcasts by William Steele on his WPF Soup To Nuts series so it could have could have come from one of those.)

What was mentioned was having both text and an image on a button.  I knew it was possible, but I didn’t know just how easy it was to do.

By default when you add an image to the button the text of the button is overlays the image.

There is a property of a button which helps us set the relation of the text to the image.  This name of this property is TextImageRelation.


The TextImageRelation property has five options:

  • Overlay
  • Image over text
  • Text over image
  • Image before text
  • Text before image

The options are pretty much self explanatory.  Below are screen shots showing the different positions.

Image over text:

Text over image:

Image before text:

and lastly

Text before image:

posted on Thursday, April 24, 2008 7:17 PM

Feedback

No comments posted yet.

Post Feedback

Title:
Name:
Url:
Comments: 
Protected by Clearscreen.SharpHIPEnter the code you see: