How to stop objects being created with a default classs

Posted on 2009-02-16
Last Modified: 2013-11-26
I'm trying to learn how to use Visual Studio 2008 for creating web pages. I find that many of the objects I create, such as Tables or Images are given a default class:


Is there any way of turning off this functionality? Or is there a way I can use it to my advantage? Usually there would already be a class in my .CSS file that I can assign to a new object.

Question by:ipendlebury
    LVL 12

    Accepted Solution


    Under Tools menue .. go to options>>
    Expand  option HTML designer and then select CSS option.

    In right pan you see inline css or class css

    by changing to inline it would not create a separate style for every element


    Author Comment

    Well it half worked. If I create a table now, it puts a: Width = 100% inside the TD tag. If I drag an image onto my page it still creates a class in the header section of my page.

    But I dont want it to do any of this. I dont want visual studio attempting to anticipate how I would like to format an object. I would like to turn off this functionality so that objects are created without any formatting. I want to format them myself.



    Author Comment

    Ok, I guess I cant prevent Visual Studio from doing this. I'll accept your reply and awards the points so I can close this thread. Thanks for your input.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    The object model of .Net can be overwhelming at times – so overwhelming that quite trivial tasks often take hours of research. In this case, the task at hand was to populate the datagrid from SQL Server database in Visual Studio 2008 Windows applica…
    More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
    Need more eyes on your posted question? Go ahead and follow the quick steps in this video to learn how to Request Attention to your question. *Log into your Experts Exchange account *Find the question you want to Request Attention for *Go to the e…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now