Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 409
  • Last Modified:

How to compile in Visual Studio 2008 with errors

I have a web application that was created by a previous programmer that I now have to make changes to. Unfortuanatly I get a few annoying errors that arn't actually errors. For example Visual Studio telling me that word-wrap is not a valid in the CSS section, which it is.

As it errors it wont compile the app is there any way to stop this and get visual studio to compile with all errors. Or treat them as warnings.
0
TheAnvilGroup
Asked:
TheAnvilGroup
  • 5
  • 2
1 Solution
 
abelCommented:
For 50p? Must be very easy to solve. Let me try: if your app does not compile, that's not because of any XML, CSS, HTML or related errors, but because of coding errors, which do matter and must be resolved in order to compile. Look lower in the list of errors and/or close any windows that show the CSS (this will remove these errors from the list, making it easier for you to see the wood for the trees).
0
 
TheAnvilGroupAuthor Commented:
It wont compile because of a) the CSS issue, which is not an error just Visual Studio not recognising a valid CSS tag and b) because it doesn't like a setting in the web.config. The only way i can see to stop this error is to spend a fair amount of time setting my development machine up like the previous guys. I really want to avoid this.

To reiterate there are no coding errors in the web application at all and it wont compile because it thinks there are. 50points because all I want to do is turn off the option to not compile if there are errors. If there is one.

0
 
abelCommented:
> do is turn off the option to not compile if there are errors.

such a thing does not exist. Suppose I would write this in web.config:

<configurationss>
    <config-Sections>

instead of

<configuration>
    <configSections>

how would the compiler possibly know what I meant. Or if I wrote "Dime bla As NoObject", how could the compiler ignore "Dime" and "NoObject"?

Your (a) is not an issue. Like I said, the CSS errors are reported but will not stop compilation. Just fix that line in web.config and you are all set. Most CSS files contain deliberate errors (i.e. to help Microsoft IE to display properly, you use properties like _width etc). Not compiling when CSS errors occur would mean that hardly any project would build.

But you don't have to take my word for it, try it, and check for yourself ;-)
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
abelCommented:
Btw, the opposite is possible. If you are referring to warnings and not errors, you can turn that into errors (they will still display as warnings, but will break compilation). You can set that on the Build-tab of the Properties of the project.

But nothing will help as long as web.config isn't fixed.

ScreenShot299.png
0
 
abelCommented:
If you want to take this one level further, what's often done with Open Source projects is that a prebuild step is used to make intermediate changes to the files that would otherwise not compile on a higher (or lower) version of Visual Studio. A fine example is the Visual Studio configuration of the Apache source, where they added prebuild steps with the awk-tool to manipulate some textfiles and fix them, without breaking backward compatibility.

If you want to go that path, take a deep breath, because it can be tricky to get right, depending on your demands, of course. You can put your custom scripts on the Build Events tab.
0
 
TheAnvilGroupAuthor Commented:
Okay so it's not possible. Thanks.
0
 
abelCommented:
I helped you out, gave you extensive information on how you can deal with it, disregarding the 50p (just as much as I love earning points, I love to learn or help out). What are you missing that you are giving a lower grade (was I slow, not giving enough information, only pointing to a link)?

Please check the 10pts must principle and give us experts the chance to earn that grade by giving feedback. And don't let "cannot be done" situation cloud your judgment.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 5
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now