Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > Avalon

Vista - File.xaml and File.xaml.cs are atomically checked out/in from sourcesafe

 
 
Old 04-19-2006   #1 (permalink)
Pascal Bourque


 
 

File.xaml and File.xaml.cs are atomically checked out/in from sourcesafe

Hi,

When I create a WinFX project in Visual Studio, it automatically
combines any XAML file with its corresponding .xaml.cs code-behind file,
like so:

<Compile Include="Window1.xaml.cs">
<DependentUpon>Window1.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>

And in the IDE, the code-behind file shows up as a "child" of the xaml
file in the Solution Explorer.

This is generally a good thing, but not quite so when it comes down to
checking in/out to SourceSafe only one file of this pair.

First, there is no way to check out the .xaml.cs file via the context
menu (nor the top-level source control menu). I need to start editing
the file for VS to prompt me to check it out.

Then, it doesn't check out only the .xaml.cs file, but the .xaml file as
well!

Also, if I modify both the .xaml and .xaml.cs files and want to undo
check-out only one of these files, it undoes BOTH files!

This behavior goes against the advertised development process that a
designer can work in the XAML file while a developer writes the code in
the .cs file...

Should this be considered a bug or simply an undesirable side effect of
the way VS/SourceSafe handle <DependentUpon> files?

As a workaround, can I safely break the <DependentUpon> relationship
manually in the csproj file?

Thanks!

Pascal

My System SpecsSystem Spec
Old 04-26-2006   #2 (permalink)
Ashish Shetty [MSFT]


 
 

Re: File.xaml and File.xaml.cs are atomically checked out/in from source safe

I've forwarded your feedback. Also, yes, you can safely break the
<DependentUpon> association without sacrificing application functionality.

--
Ashish Shetty [MSFT]
Program Manager, Windows Presentation Foundation (Avalon)
Blog: http://nerddawg.blogspot.com



"Pascal Bourque" <bourquep@xceedsoft.com> wrote in message
news:O0MLOg7YGHA.3400@TK2MSFTNGP02.phx.gbl...
> Hi,
>
> When I create a WinFX project in Visual Studio, it automatically combines
> any XAML file with its corresponding .xaml.cs code-behind file, like so:
>
> <Compile Include="Window1.xaml.cs">
> <DependentUpon>Window1.xaml</DependentUpon>
> <SubType>Code</SubType>
> </Compile>
>
> And in the IDE, the code-behind file shows up as a "child" of the xaml
> file in the Solution Explorer.
>
> This is generally a good thing, but not quite so when it comes down to
> checking in/out to SourceSafe only one file of this pair.
>
> First, there is no way to check out the .xaml.cs file via the context menu
> (nor the top-level source control menu). I need to start editing the file
> for VS to prompt me to check it out.
>
> Then, it doesn't check out only the .xaml.cs file, but the .xaml file as
> well!
>
> Also, if I modify both the .xaml and .xaml.cs files and want to undo
> check-out only one of these files, it undoes BOTH files!
>
> This behavior goes against the advertised development process that a
> designer can work in the XAML file while a developer writes the code in
> the .cs file...
>
> Should this be considered a bug or simply an undesirable side effect of
> the way VS/SourceSafe handle <DependentUpon> files?
>
> As a workaround, can I safely break the <DependentUpon> relationship
> manually in the csproj file?
>
> Thanks!
>
> Pascal



My System SpecsSystem Spec
 

Thread Tools


Similar Threads
Thread Forum
Event in Xaml vs c# file. .NET General
Is it possible to include XAML files into another XAML file? .NET General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46