Slow and steady Silverlight (6)-2.0 control Scrollviewer,slider,stackpanel,tabcontrol,textblock,textbox,togglebutton
Online Demo
Http://www.cnblogs.com/webabcd/archive/2008/10/09/1307486.html
Example
1, Scrollviewer.xaml
<usercontrol x:class= "Silverlight20.Control.ScrollViewer"
Xmlns= "Http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x= "Http://schemas.microsoft.com/winfx/2006/xaml" >
<StackPanel>
<!--
Content in the Scrollviewer.content-scrollviewer control
HorizontalScrollBarVisibility-Display status of horizontal scroll bars
Verticalscrollbarvisibility-Display status of vertical scroll bars
Auto-automatically determines whether scroll bars are displayed based on the width and height of the ScrollViewer and the width and height of the content.
Disabled-not displayed, but you can see the blocked content by moving or dragging through the keyboard or mouse in the display content
Hidden-not displayed, and cannot see the blocked content
Visible-Show scroll bars
-->
<scrollviewer margin= "5" width= "height=" horizontalalignment= "left" horizontalscrollbarvisibility= "Auto "verticalscrollbarvisibility=" Auto ">
<ScrollViewer.Content>
<image source= "/silverlight20;component/images/logo.jpg" width= "/>"
</ScrollViewer.Content>
</ScrollViewer>
<scrollviewer margin= "5" width= "height=" "horizontalalignment=" left "horizontalscrollbarvisibility=" Auto "verticalscrollbarvisibility=" Auto ">
<TextBox>
<TextBox.Text>
Aaa
Bbb
Ccc
Ddd
Eee
Fff
Ggg
Hhh
Iii
Jjj
Kkk
lll
Mmm
nnn
</TextBox.Text>
</TextBox>
</ScrollViewer>
</StackPanel>
</UserControl>