Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » LINQ to XML   (RSS)
Announcing the First CTP of Open XML SDK V2
Today, the development team for the Open XML SDK has announced that they have released the first Community Technology Preview (CTP) of version 2 of the Open XML SDK. Download it at http://go.microsoft.com/fwlink/?LinkId=127912 . There is a lot of very Read More...
Using LINQ to XML to Retrieve Content Controls in Word 2007
Content controls are an effective way to add structure to word processing documents. You can write a very small LINQ query to retrieve the contents of content controls. This topic in Office Online provides more information on content controls. In an upcoming Read More...
Use a Lambda Expression for an Event Handler
You can use lambda expressions to write an event handler, even for classes that predate C# 3.0 and the latest version of the framework. This can shorten your code, and make it easier to read. For example, the code to validate an XML tree using an XSD Read More...
Object Dumper: An Invaluable Tool for Writing Code in the Functional Programming Style
When developing C# programs in the functional programming style, you often need to dump out a collection to the console. Object dumper is a great tool to use for this. It is a sample that far too few developers know about. A functional transform typically Read More...
LINQ Reduces Line Counts and Makes Code “Pop”
Just as soon as I learn something, I blog it. This has a potential pitfall – sometimes I blog something and then learn that my approach was incorrect. But I’m not too awfully proud – I just blog again and tell you my new lessons learned. Nearly two years Read More...
Are Developers Using LINQ? (Part 2)
The response to my previous blog post has been very interesting to me. And it has, to a very large extent, matched my own experience. I have seen four basic scenarios where folks use LINQ: Using LINQ to Objects (and LINQ to XML, which is really just LINQ Read More...
Are Developers Using LINQ?
I had an interesting conversation with my nephew the other day. He is a very bright CS student working as a summer intern at a software company (not Microsoft). He is programming in C# using Visual Studio 2008. I asked him if developers at his company Read More...
Removing Comments and Personal Information, and Accepting Revisions in an Open XML Document Stored in SharePoint
This post presents a custom application page in SharePoint that uses Open XML, the Open XML SDK and LINQ to XML to accept revisions, remove comments, and remove personal information from an Open XML word processing document. The following 45 second screen-cast Read More...
Writing Robust LINQ to XML Code that Performs Well
In the last three posts, in addition to the information regarding how we want to alter the markup in an Open XML document, I've made a few observations about how to write LINQ to XML code when modifying an XML tree in such a way that it becomes harder Read More...
Using the Open XML SDK and LINQ to XML to Remove Comments from an Open XML Wordprocessing Document
This post presents a snippet of code to remove comments from an Open XML Wordprocessing document. Note: This post may be of interest to LINQ to XML developers, as it contains some information that helps you write queries that perform better. In the case Read More...
Using the Open XML SDK and LINQ to XML to Remove Personal Information from an Open XML Wordprocessing Document
This post presents some code to remove personal information from an Open XML word processing document. Note: this post contains interesting information for LINQ to XML developers even if you are not interested in removing personal information from a document. Read More...
Using the Open XML SDK and LINQ to XML to Accept Revisions in an Open XML Wordprocessing Document
In this post, I present some code that uses the Open XML SDK and LINQ to XML to accept all revisions in an Open XML word processing document. So, for example, if we have this document: And we run this code, the document then looks like this: The main Read More...
How to Create Hierarchy from Flat Data using LINQ
This is a fun, geeky post for those interested in functional programming. Sometimes you have flat data where there is hierarchy expressed in the data, but the form of the data is flat. You may need to transform this data into a hierarchy, such as an XML Read More...
Open XML SDK and LINQ to XML
In this post, I’m presenting some code that uses the Open XML SDK and LINQ to XML to query an Open XML document. I’ve posted on this before , but this version is cleaner and smaller. It also is an example of code written in the functional style . The Read More...
Using Annotations to Transform LINQ to XML Trees in an XSLT Style (Improved Approach)
You can use LINQ to XML to transform XML trees with the same level of power and expressability as with XSLT, and in many cases more than with XSLT. One of the reasons that XSL is so powerful is that you can write multiple rules to transform a node. The Read More...
More Posts Next page »
Page view tracker