XAML Copyright Header

1.7k Views Asked by At

Is there a standard for placing copyright statements in XAML files? In .cs files I use the following:

//-----------------------------------------------------------------------
// <copyright file="MyFile.cs" company="MyCompany" year="2011">
//
//                          COPYRIGHT INFORMATION
//  
//   ....Our Copyright...
//  
// </copyright>
//-----------------------------------------------------------------------

Is there something equivalent for XAML files?

1

There are 1 best solutions below

0
On BEST ANSWER

XAML is just XML at it's base, so you can use XML comments

<!-- Comment here -->

You could even use the XML documentation format within the comment (although there is no real point, as the XML doc generator does not process XAML files afaik.)

<!--
<copyright file="filename" company="CompanyCo" year="2011">
Copyright Info
</copyright>
-->

One small warning though, which if you work with XML at all is probably already known: You can't nest XML comments.

<!--
    In a comment
    <!--
        In a nested comment
    -->
    No longer in a comment!
-->

Just look at the code formatting above =)