问题
I'm trying to add a WrapPanel to my app, up to now I found that WrapPanel is only available through SilverLight Toolkit here http://silverlight.codeplex.com/releases
I've downloaded it and installed it, but now what do I do?
I assumed that a reference needed to be added but I can't think of what to add.
回答1:
Add a reference to Microsoft.Phone.Controls.Toolkit.dll. The WrapPanel
control is in the Microsoft.Phone.Controls namespace.
In your page/user control, add the following XML namespace declaration:
xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"
Then you can add instances of <toolkit:WrapPanel />
in your XAML.
来源:https://stackoverflow.com/questions/6954835/wrappanel-for-windows-phone-7