Stop Visual Studio 2008 From Wrapping Lines When Formatting Code?

May 20, 2010

I have an annoying problem with Visual Studio 2008.

When I run the "format code" command ("control+k, control+d") -- it will insert a carriage return. How do I get it to stop doing this?

For example:

<label for="shipCompanyName">Company Name:</label>

undesirably becomes

<label for="shipCompanyName">
Company Name:<label />

View 2 Replies


Similar Messages:

Prevent Visual Studio From Formatting <% %> On Two Lines?

Jul 22, 2010

how to make the formatting also apply to the ASP.NET server side tag <% %>

Like the related question, a block like this one

Good

<ul id="menu">
<li><%: Html.ActionLink("Home", "Index", "Home")%></li>
<li><%: Html.ActionLink("About", "About", "Home")%></li>
</ul>

Will get formatted into

Bad

<ul id="menu">
<li>
<%: Html.ActionLink("Home", "Index", "Home")%></li>
<li>
<%: Html.ActionLink("About", "About", "Home")%></li>
</ul>

I want to prevent Visual Studio from changing the formatting concerning asp.net server tag <% %>.

View 1 Replies

Visual Studio :: Total Lines Of Code In A Project?

Dec 8, 2010

Any quick way to get a count on all the lines in a project?

That way you can use the info to try and convey the complexity of a project to a Customer.

Visual Studio 2010

View 1 Replies

Visual Studio 2008 - Finding Tools For Visual Studio 2008 Which Can Reformat ASPX Code

Jan 6, 2010

Is there any tool for Visual Studio 2008 which can reformat ASPX code to make it more presentable (eg insert line breaks, format the lines so they wrap when necessary, etc)?

View 5 Replies

Visual Studio 2008 SP1 - How To Stop Debugging In Other Browsers Than IE

Mar 1, 2010

Visual Studio has integrated debugging in IE, when you close IE, it stops debugging, and if you stop debugging, VS closes IE.

I want it to do the same thing with firefox/chrome!

View 2 Replies

Visual Studio :: Can Visual Studio 2008 Be All In One Tool To Integrate Source Code Continuously

Jan 20, 2010

can Visual Studio 2008 be All-In-One tool to integrate source code continuously from team members, build, unit test?

Having used Visual Studio Team Edition 2005, unit testing each method within VS itself. I strongly believe that it is feasible to add-on tools. Example ankhsvn tool to use SVN from Visual studio [URL]

In my investigating i have come across number of tools(shown below) to use with Visual Studio 2008 professional

Development tool:- Visual Studio 2008 professional using Subversion as source control tool. Continuous Integration:- Hudson or Cruise control Build tool:- NAnt Testing:- NUnit, Selinium As Visual Studio 2008 can be used for unit testing I think NUnit is out of consideration.

In the same way i would like to have any other tools/add-ons to Visual studio to implement continuous integration, building and unit testing. This process should be automated such a way source code between team members is continuously integrated, built and unit testing is done as configured.

Objective is to use few number of tools as add-on to Visual Studio or achieve most from Visual studio itself (example unit testing). Visual Studio should be all in one tool.

I am aware that Team Foundation Server best suits my requirement, but it is out of scope due to its cost.

View 3 Replies

Visual Studio :: Format The Javascript Code On 2008?

Apr 12, 2010

I copied a heap of javascript code to my page. I need to modify it. But the formatting is messed at the same time.The brace brackets don't match. Is the a good way to format it?

View 3 Replies

Visual Studio :: Multiview In Designer Adding Horizonal Scrollbars Not Wrapping Text?

May 13, 2010

I wonder if this is either a bug or a setting I could potentially change.

I uploaded a YouTube video of the behavior since it's easier to see: [URL]

I've got a Multiview control with a View (call it view1) inside it. When I type text into view1 within the Design view of Visual Studio 2010, if the text reaches the end of the visible line it does not wrap to the next line as expected (like a div or p tag would do outside the multiview control). Instead, it extends the multiview horizonally and the horizonal scrollbar appears.

View 1 Replies

C# - Prevent Visual Studio 2008 From Rewriting Inline Code?

May 4, 2010

When writing inline code in an .aspx file and some lines down closing a statement with <% } %>, Visual Studio tries to be nice but messes it up by rewriting it all. Is there any way of turning this rewriting off, but only for inline code?

View 2 Replies

Visual Studio :: How To Convert Whole Visual Studio 2008 Web Site Project To Visual Studio 2010

Aug 14, 2010

is it possible to convert whole visual studio 2008 web site project to visual studio 2010 web site project

my current project references

i have a very annoying iis problem

iis server stops working until app pool is recycled

i am hoping that new visual studio (net framework 4.0) may solve this very annoying unsolveable problem

View 2 Replies

C# - Visual Studio 2005 Vs. 2008 - Code The Designer Automatically Generates In 08 Like In 05?

Nov 1, 2010

So I am a beginner with .NET, Visual Studio, C#, etc. But I am wondering something about the code behind a form and a difference I am seeing in 2008 versus 2005. So lets say I have a simple Windows Form app, C#, and I throw a couple controls on it. Then I add some MessageBox.Show event handlers for the default events....in 2005 there is that little section within the code that is hidden that basically contains the code that 'registers' the controls with the system....I think. That may be a bad definition?? Basically I think that automatic code generated here just basically associates the event to the event handling code....anyway.

I can see this is 2005 (once I click the like gray box), but it does not appear anywhere in 2008. So this has to exist somewhere, and I just wanted to ask to be familiar with what is going on since I am new to this. I still have to figure out how to turn on the code line numbering in 2008, but I can google it.

View 2 Replies

Visual Studio :: Reassociating A Code Behind File With .aspx In 2008 Website Solution

Feb 12, 2010

I can't get my .aspx page to recognize control events in it's codebehind.

[Code]....

which is fine, but I don't want to use inline script.

[Code]....

View 6 Replies

Visual Studio Macro - Read First X Lines Instead Of Entire Document?

Jul 5, 2010

I've got a macro that updates a copyright header with the most recent edit date.

The problem I have is that the macro currently reads through the entire file rather than just the first 6 lines (which is all it needs).

Is there a way to get the Macro to only read the first "X" lines rather than the entire file?

Private selection As EnvDTE.TextSelection = DTE.ActiveDocument.Selection
Private Sub UpdateCopyrightHeader()
selection.StartOfDocument()
selection.EndOfDocument(True)
Dim content As String = selection.Text
Dim result = System.Text.RegularExpressions.Regex.Replace(content, regex, "<lastedit>" & FormatDateTime(Date.Now, vbLongDate) & "</lastedit>")
selection.Delete()
selection.Collapse()
Dim ed As EditPoint = selection.TopPoint.CreateEditPoint()
ed.Insert(result)
End Sub

View 1 Replies

Visual Studio :: Inordinate Pauses When Indenting Lines Of HTML?

Jan 18, 2010

An example: I have a fairly simple "contact us" kind of HTML form. No controls, just straight HTML, total size of aspx file is 570 lines. There is a Country drop-down list, with roughly 240 lines of "<option value="..">..</option>, one for each country.

Say I need to change the indent of those option lines. I select all ~240 of them, hit TAB and.... wait.

and wait...

and wait...

Finally, VS recovers from whatever trauma I've inflicted upon it, having successfully indented the lines. We actually have other coders getting up with an audible sigh, and going to make coffee in frustration while this sort of thing happens. Just from changing the indent of a bunch of HTML. It also happens when doing a find & replace on that same selection of 240 option lines... huge pause!

Would something be wrong with our setup? Some options (HTML intellisense-related perhaps) which we can adjust so VS doesn't go catatonic when we simply want to change indent? I've resorted to pasting stuff into TextPad, doing the indenting/replacing/whatever, then pasting it back into VS. That can't be an industry standard practice, I can only assume something is off with our installs.

VS's reaction reminds me of Kylie from Fantastic Mr Fox. Select some HTML, hit TAB and...

View 3 Replies

Visual Studio :: Opening Visual Studio 2008 Project In Visual Studio 2010?

May 21, 2010

Anyone know if I can maintain a VS 2008 (.net 3.5) project by using the VS 2010 IDE ?

View 1 Replies

Visual Studio :: Connect Visual Web Developer 2008 Express Edition To SQL Server 2008?

Sep 11, 2010

i have created a login.aspx file in visual web developer .now i want to connect the username and password details to SQL database

View 1 Replies

DataSource Controls :: Connecting To SQL Server In Visual Studio 2008 Using Code - Error: 25 - Connection String Is Not Valid

Feb 2, 2010

Background: I use SQL server 2005 developer edition and visual studio 2008. Visual studio 2008 is running on a local machine with Vista business edition. SQL server is running on a remote server using Windows server 2003. Both computers are within the same domain.

Problem: First, I used the server explorer to connect to the SQL server. Everything works as desired. Then I write code to do the same thing. I keep getting the following error message:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 25 - Connection string is not valid)

However, I used the exactly identical connection string as the one used in the server explorer. So connection string should not be the problem. In addition, I tried the test code in MSDN, which tells whether my domainusername can flow the network. It turns out the user name is fine. I also went to the SQL server management studio and found the login for my computer is NVCWeihao while my computer login name is NVCweihao. I am wondering if this uppercase letter really affects the connection.

View 2 Replies

Visual Studio :: Formatting Tool Bar?

Sep 28, 2010

i have installed visual studio 2010. But when i add a new tool bar like "layout". It all options appears disable (mean i cant select any option). Please how will i enable these options.

View 1 Replies

Visual Studio :: CSS Stopped Auto Formatting?

Jan 27, 2010

I'm not sure what happened, I didn't change any settings. For example, i could type the following:

a{

then hit return, and get

a
{

Now though nothing happens. It's not formatting like it used to. where I can set this or switch it back? I checked Tools > Options > CSS but couldn't find anything there that fixed it.

View 3 Replies

Visual Studio :: Unable To Install Visual Studio 2008 Professional Edition?

Aug 8, 2010

I downloaded Visual Studio 2008 Professional Edition via torrent.

It was working fine for months & i formatted my comp & when i tried to reinstall it is not getting installed !

It shows the following error !

and the error log file seems to be like this...

BUT.,

I'm able to use Visual Studio & i'm able to work in it....

I'm re-installing since 2 days for more than 4 times...

View 1 Replies

Visual Studio :: Unit Test Visual Studio 2008 Professional Edition?

Mar 1, 2010

I have VS 2008 Professional Edition.....I want to test a function like this:

public int getIdByName(string name)
{
var item=from x in DATAB
where x.name=name
select x.id;
.
.
return idValue;
}

now I test end I have:

[TestMethod()]
public getIdByNameTest()
{
string name="Bob"
int expected = 1;
int actual;
actual = ClassGET.getIdByName(name);
Assert.AreEqual(expected, actual);
Assert.Inconclusive("Verify the correctness of this test method.");
}

The error in "test run" is:

Failed ......[Class]....... Test method threw exception: System.ArgumentException: The specified named connection is either not found in the configuration that is not for use with the EntityClient provider or thought is invalid

View 7 Replies

Visual Studio :: Ensure Web Application Converted From 2003 Visual Studio To 2008?

May 28, 2010

How can I ensure that web application converted from 2003 visual studio to 2008 visual studio

to have two files as it is when create a web file in visual studio 2008.The web application is in Chsarp. I have converted these filesfrom 2003 to 2008 but they still have three files each.

View 4 Replies

Visual Studio :: Formatting Not Working For C# (Win7 X64 SP1, VS2011 X62 SP1)

Mar 25, 2011

I just can't seem to get C# code to auto-format, despite having gone over all the Formatting options for c# to make sure they are correct. For example, I want brackets to auto-format to a new line, but nothing changes. I want catch keywords to automatically go to a new line, yet they don't. The options are checked in Formatting under C#, so what gives? HTML formatting works, and prop-tab-tab works in c#, but new line formatting and such does not.

View 1 Replies

Visual Studio Auto Formatting Not Working On The Aspx Page?

Oct 14, 2010

I am running Visual Studio 2008. I cannot get the auto format to work on the source code of my aspx page. I have tried it from the edit menu and the ctrl K, D. Nothing works. If I manually fix everything, the next time I open the file the formatting is gone. Here is a sample of what it looks like:

[Code]....

View 2 Replies

Visual Studio 2008 Guidance Package To Visual Studio 2010

Aug 11, 2010

I am trying to convert guidance package of vs2008 to vs2010,

followed instructions as per this link {http://msdn.microsoft.com/en-us/library/ff697211.aspx}

and getting error as

Error 1 The "GenerateMenuResource" task failed unexpectedly....

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved