How To: Visually create .SKIN files in Visual Studio for Themes

Rate It (1)

Last post 10-14-2009 6:07 PM by BuckyP. 1 replies.

Sort Posts:

  • How To: Visually create .SKIN files in Visual Studio for Themes

    03-21-2008, 7:59 PM
    • Member
      49 point Member
    • awd_envy
    • Member since 01-03-2006, 3:47 AM
    • Posts 32

    I didn't find this anywhere and it was driving me crazy... so I thought I'd post a solution for someone else in case they need it.

    Creating .SKIN files by copy and pasting the controls is one of the BIGGEST drawbacks of the skinning system in my opinion (followed closely by CSS load order and CSS Media definement). Insted I would rather Drag and Drop controls and edit them in the Skin page; or look at the skin in design view to see what my skin actually looks like.  Below is my solution to do this in Visual Studio (should work in Visual Web Developer as well).

     

    To Visually Create Skin files in VS 

    In Visual Studio....

    1. Tools > Options
    2. Under "Text Editor"  click on "File Extension"
    3. Type "skin" in the "Extension" textbox
    4. Select "Web Form Editor" under the "Editor" dropdown list.
    5. Click "ADD"
    6. Click "OK"

    Thats It!  Whenever you open a skin file you'll now have the toolbox and the Design view (or split view in VS08). Drag and Drop to the CODE window. If you drop to the design window, the editor will add the <Form> tag  to the document, and the ID field to the control.  Both of which cannot be in a SKIN file. After the control is on the page, you can change it's styles in the design view like normal.

    Note: If you have any SKIN files open before you do this, you'll need to close and reopen them for the changes to take effect. 

  • Re: How To: Visually create .SKIN files in Visual Studio for Themes

    10-14-2009, 6:07 PM
    • Member
      2 point Member
    • BuckyP
    • Member since 10-14-2009, 6:02 PM
    • Posts 1

    Thanks for that, it works great.

    You can also use the "User Control Editor" to avoid the markups everywhere.

Page 1 of 1 (2 items)