Click here to Skip to main content
11,492,523 members (56,955 online)
Click here to Skip to main content

Tagged as

Custom WPF TextBox Style

, 28 Dec 2010 CPOL 19.5K 2
Rate this:
Please Sign up or sign in to vote.
TextBox Style which resembles the Twitter's text field.
Download TwitterTextBox for WPF Demo and Source Code



View Image



Introduction



This tip was written to demonstrate how to customize the rendering of the standard TextBox control provided by Microsoft. You can use this custom style to achieve the Twitter's TextBox look and feel.

Using the Style



To make use of the custom Style you need to set the Style property of your TextBox controls.

The example code below demonstrates how to apply the style:

 <TextBox Style="{StaticResource TwitterTextBoxStyle}" Height="25" Name="textBox1" Width="300" />

Points of Interest



I have made this TextBox Style as part of my university project. I wanted to add to my application some cool glow effects and animations.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

John_Smith78
Software Developer
United States United States
No Biography provided

Comments and Discussions

 
GeneralReason for my vote of 1 not helpful Pin
st0rmrd17-Aug-11 2:36
memberst0rmrd17-Aug-11 2:36 
GeneralThanks for the code sample, just what I needed! Pin
Riaan77721-Jul-11 1:56
memberRiaan77721-Jul-11 1:56 
GeneralThis is just a short article(tip), it should not be too long... Pin
John_Smith785-Jan-11 0:52
memberJohn_Smith785-Jan-11 0:52 
GeneralJohn i am well versed with WPF! but what about others? you s... Pin
Tarun.K.S30-Dec-10 8:38
memberTarun.K.S30-Dec-10 8:38 
GeneralThe provided Style definition extends the standard TextBox's... Pin
John_Smith7829-Dec-10 3:19
memberJohn_Smith7829-Dec-10 3:19 
GeneralReason for my vote of 2 No explanation at all! Pin
Tarun.K.S29-Dec-10 2:17
memberTarun.K.S29-Dec-10 2:17 
GeneralStill no explanation of what this is all about. Pin
Richard MacCutchan24-Dec-10 7:27
mvpRichard MacCutchan24-Dec-10 7:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.150520.1 | Last Updated 28 Dec 2010
Article Copyright 2010 by John_Smith78
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid