MS.COM Operations Tools Team WebLog

Hey - What does this button do?

Open in Code View

For those of you who like certain control classes to open in the code view (instead of the designer view) by default.  You can use the following attribute on your class so when you double click on it you get the code view.

  • [System.ComponentModel.DesignerCategory("Code")]

I know this has been a nicety that I now use often.

Enjoy,
eHowitzer

p.s. I tried this on a simple winform (on the form class) and windows service application (on the main service class) and it allowed me to open the classes in code view by default.  The web service application I tried it with didn't open in code view however. :-( 

p.p.s.  I would have posted these as additional comments, but for some reason I can't seem to comment on blogs currently.

Published Friday, October 29, 2004 10:36 AM by mscomts

Comments

 

Random Thoughts said:

Open in Code View...
October 29, 2004 1:59 PM
 

Jeff Parker said:

Hmm, any idea how you would do this for Web Services, Windows Services?

Most annoying thing in there. Windows Services, Web Services have no real visible UI, yet opening them you prested with a blank white screen with a link saying click here to switch to code view. Dumb extra click
October 29, 2004 12:30 PM
 

Cook Computing said:

The MS.COM Operations Tools Team WebLog has a useful tip if you working with component classes in .NET:For those of you who like certain control classes to open in the code view (instead of the designer view) by default. You...
October 30, 2004 5:40 AM
 

Jake Good said:

Now if this worked for Windows Forms classes..
November 1, 2004 11:51 AM
 

Anonymous said:

I tested this against a simple winform application and a windows service application and they both opened in code view.

It didn't work for a web service application however. :-(

eHowitzer
November 2, 2004 8:23 AM
 

About the Duwamish7.0 | keyongtech said:

January 22, 2009 5:14 AM
New Comments to this post are disabled

This Blog

Syndication

Tags

No tags have been created or used yet.

News

All opinions posted here are those of the author(s) and are in no way intended to represent the opinions of our employer. This is provided "AS IS" with no warranties, and confers no rights. Use of included code samples are subject to the terms specified in the Terms of Use.

© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Microsoft
Page view tracker