Click here to Skip to main content
15,847,077 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In WPF you can you findresource to find staticresource, like so:
Button b = new Button();
b.Style = (Style)FindResource("CustomButton");

I'm trying to do the same in WP7/Silverlight but FindResource is unavailable. Is there a way to reference the button that I created dynamically to a staticresource? Please help.

Thanks in advance!
Updated 22-Jan-11 10:22am

1 solution


BTW you would have hit upon that blog within the first page of a reasonably well-worded google search.
Share this answer

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

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900