DotNetKick.com is an open-source project. Please report any bugs and let us know your great suggestions. Currently running svn revision 620 (rss)

Kick Spy!, Kick Zeitgeist and Kick Widgets

wisemx Subscribe to this feed
wisemx
Profile Kicked Submitted Comments Tags Friends Kicked By Friends Submitted By Friends

Member Since: Saturday, January 12, 2008 (8 months, 28 days ago)
Last Seen: 11 hours, 51 minutes ago Who else is online?
Location: Johnson City, TN. U.S.A.
Website: http://msftwise.com

Friends With:

Friends By:

Kick Spy:

wisemx wisemx shouted something: (19 hours, 18 minutes ago):
wisemx wisemx kicked Place a StackOverflow badge on your website: (19 hours, 21 minutes ago):
wisemx wisemx tagged Why don't Beta 2 sites work on RC0 with : (1 day, 16 hours ago):
wisemx wisemx kicked Why don't Beta 2 sites work on RC0: (1 day, 16 hours ago):
wisemx wisemx submitted Why don't Beta 2 sites work on RC0: (1 day, 16 hours ago):
wisemx wisemx commented on Downloading Videos From YouTube: (1 day, 19 hours ago):
wisemx wisemx commented on YouTube project Engine in ASP.NET: (1 day, 21 hours ago):
wisemx wisemx shouted something: (2 days, 20 hours ago):
wisemx wisemx tagged Touchless - A webcam multi-touch SDK with : (3 days, 15 hours ago):
wisemx wisemx kicked Touchless - A webcam multi-touch SDK: (3 days, 15 hours ago):
wisemx wisemx submitted Touchless - A webcam multi-touch SDK: (3 days, 15 hours ago):
wisemx wisemx shouted something: (3 days, 19 hours ago):
wisemx wisemx shouted something: (4 days, 20 hours ago):
wisemx wisemx shouted something: (7 days, 19 hours ago):
wisemx wisemx shouted something: (7 days, 21 hours ago):
wisemx wisemx kicked jQuery, Microsoft, and Nokia: (12 days, 12 hours ago):
wisemx wisemx tagged Updating Silverlight 2 Beta 2 Demos to RC0 with : (14 days, 15 hours ago):
wisemx wisemx kicked Updating Silverlight 2 Beta 2 Demos to RC0: (14 days, 15 hours ago):
wisemx wisemx submitted Updating Silverlight 2 Beta 2 Demos to RC0: (14 days, 15 hours ago):
wisemx wisemx tagged Welcome to SQL Server 2008 Patching with : (14 days, 19 hours ago):
wisemx wisemx kicked Welcome to SQL Server 2008 Patching: (14 days, 19 hours ago):
wisemx wisemx submitted Welcome to SQL Server 2008 Patching: (14 days, 19 hours ago):

Shoutbox

Jemm Jemm said (2 months, 17 days ago):
something
Jemm Jemm said (3 months, 27 days ago):
Great:) DNK has been in need of your quality posts :)
wisemx wisemx said (3 months, 27 days ago):
I did run away from all the spam but was drawn back by the sense of Community.
Rotten 1%ers spoil it for the nice guys. ;-)
Jemm Jemm said (3 months, 28 days ago):
W00t! You are back:)
wisemx wisemx said (7 months, 14 days ago):
Give this question a break until we get the updates during or just after Mix 08 ;-)
yesthatmcgurk yesthatmcgurk said (7 months, 14 days ago):
One more question...

Have you ever heard of embedding binary resources as string within XAML? I'd love to be able to have an image on a XAML document and have it serialized to a string resource inside the .xaml text. Managing resources in a separate file will be an issue for me in the future...
yesthatmcgurk yesthatmcgurk said (7 months, 14 days ago):
Thanks. I read over the article; it did give me some hints. I managed to get my xaml template -> XPS document code working. Get this...
For each DataRow
FixedPage xaml with layout and controls is loaded into a MemoryStream and fed to the XamlReader.
Data is bound to this template.
Template is configured for the page's resolution and size and its layout is updated.
A PageContent is created and the FixedPage template is set as its child
The PageContent is added to a FixedDocument.
When all data rows have been merged, an XpsDocumentWriter is created and the fixed document's DocumentPaginator is Write()'d.

Result: Xaml template + data -> XPS document.

Sweet.
wisemx wisemx said (7 months, 18 days ago):
I think just reading the default overview in the link below will be what you are looking for, especially the content/object properties for XAML:
http://msdn2.microsoft.com/en-us/library/ms752059.aspx
yesthatmcgurk yesthatmcgurk said (7 months, 18 days ago):
K, I'm busy too.
First question:

Coming from the windows forms/aspnet world, patterns for newing up forms and accessing controls aren't the same with XAML and WPF.
(everything I'm doing is currently in 2005) Lets say I have a DLL project. I add a new FlowDocument (WPF) to the project. This creates FlowDocument1.XAML. I open this up and see markup similar to an aspnet page. Great. I add a Paragraph and a TextBlock with Name="Lol" to the FlowDocument node in the XAML editor. I add the attribute Name="MyFlowDocument" to the root FlowDocument node. The XAML document does not have a codebehind file, nor does it have inline code.

Now, what I want to do is "new" up the object described by this XAML document: FlowDocument fd = new MyFlowDocument() and I want to access the TextBlock: fd.Lol.Text = "Hai from WPF!"

This, of course, does not work. How do I manipulate XAML documents like this in code? Bonus question: how could I do this generically--for any WPF document (FrameworkElement?), if it has a TextBlock with a name of "Lol", set the text to equal the above?
TIA.
wisemx wisemx said (7 months, 18 days ago):
I like the idea of hashing it here, makes it public and I'm all for community.
Sorry it took me a day to get back, was away.
yesthatmcgurk yesthatmcgurk said (7 months, 18 days ago):
Hai, thanks for the offer to help.
So, this xaml thing... I have a number of questions that I'm having a hard time wrapping my head around, but the shoutbox here is kinda small. What do you think?
 

Sponsored Link: www.carlist.ie

Search:

Ads via The Lounge