Hello all..
In the VS.Net IDE, is there a way to auto-format your code (such that
the curly braces for code blocks automatically align, code is
automatically indented to proper levels etc)? If not in 2003, will this
feature be available in 2005?
It sux to deal with so much variation in code formatting style between
different programmers. At least VB.net makes formatting consistent by
default. I promise to stop complaining if you will tell me how to do
this in C# :) 4 3674
select all code in the window (ctrl-a)
then
ctrl-k ctrl-f
Also in the menu under Edit->Advanced->Format Selection
Formats all selected code in window.
I know your pain. ;)
jim
"JavaGeekRo yR" <de*******@hotm ail.com> wrote in message
news:10******** *************@f 14g2000cwb.goog legroups.com... Hello all..
In the VS.Net IDE, is there a way to auto-format your code (such that the curly braces for code blocks automatically align, code is automatically indented to proper levels etc)? If not in 2003, will this feature be available in 2005?
It sux to deal with so much variation in code formatting style between different programmers. At least VB.net makes formatting consistent by default. I promise to stop complaining if you will tell me how to do this in C# :)
JavaGeekRoyR,
There is no support for this in VS.NET 2003, but in VS.NET 2005, there
is a huge amount of support for formatting. You can find it under "Tools |
Options"
Then in the dialog that shows up, go to "Text Editor | C# | Formatting"
and you can see a number of options relating to the formatting that the IDE
applies to your code.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m
"JavaGeekRo yR" <de*******@hotm ail.com> wrote in message
news:10******** *************@f 14g2000cwb.goog legroups.com... Hello all..
In the VS.Net IDE, is there a way to auto-format your code (such that the curly braces for code blocks automatically align, code is automatically indented to proper levels etc)? If not in 2003, will this feature be available in 2005?
It sux to deal with so much variation in code formatting style between different programmers. At least VB.net makes formatting consistent by default. I promise to stop complaining if you will tell me how to do this in C# :)
what am i missing here ?
in vs.net 2003 ( and afaik all previous versions ) typing a closing brace
formats all code back to the matching opening brace.
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard .caspershouse.c om> wrote in
message news:%2******** ********@TK2MSF TNGP10.phx.gbl. .. JavaGeekRoyR,
There is no support for this in VS.NET 2003, but in VS.NET 2005, there is a huge amount of support for formatting. You can find it under "Tools
| Options"
Then in the dialog that shows up, go to "Text Editor | C# |
Formatting" and you can see a number of options relating to the formatting that the
IDE applies to your code.
Hope this helps.
-- - Nicholas Paldino [.NET/C# MVP] - mv*@spam.guard. caspershouse.co m
"JavaGeekRo yR" <de*******@hotm ail.com> wrote in message news:10******** *************@f 14g2000cwb.goog legroups.com... Hello all..
In the VS.Net IDE, is there a way to auto-format your code (such that the curly braces for code blocks automatically align, code is automatically indented to proper levels etc)? If not in 2003, will this feature be available in 2005?
It sux to deal with so much variation in code formatting style between different programmers. At least VB.net makes formatting consistent by default. I promise to stop complaining if you will tell me how to do this in C# :)
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: deko |
last post by:
Do I need to use curly brackets in PHP if .. else statements? other constructs?
Does it matter? What are Best Practices? Why?
thanks in advance...
This seems to work WITHOUT curly brackets:
if(ereg("Win", getenv("HTTP_USER_AGENT")))
$visos = "Windows";
elseif((ereg("Mac", getenv("HTTP_USER_AGENT"))) || (ereg("PPC",
|
by: Ken in Melbourne Australia |
last post by:
If I use the curly bracket syntax (referred to as the
complex syntax) within a string, how do I get to call a
function within it?
The php manual says that the first (or previous)
character for the curly bracket has to be a dollar sign '$'.
This is fine for variables, arrays and some objects but
doesn't allow me to call a function such as...
|
by: Dustin D. |
last post by:
Let's say I have a text file with the following:
food {
fruits {
apples
oranges
pears
}
dairy {
ice_cream {
|
by: STF |
last post by:
While reading the C++ tutorial in this page:
http://www.cplusplus.com/doc/tutorial/tut2-2.html
I'm astonished to learn that we could omit curly brackets in function
declaration for single instruction as is written in the paragraph:
"statement is the function's body. It can be a single instruction or a
block of instructions. In the latter...
|
by: JavaGeekRoyR |
last post by:
Hello all..
In the VS.Net IDE, is there a way to auto-format your code (such that
the curly braces for code blocks automatically align, code is
automatically indented to proper levels etc)? If not in 2003, will this
feature be available in 2005?
It sux to deal with so much variation in code formatting style between
different programmers....
| |
by: krbyxtrm |
last post by:
Hi
is there a way to 'manage' function execution using macros?
#define MY_CALL_MACRO(MacroName)
{ g_MacroStack.push_back(MacroName);
<some code here...>}
such that when i use the macro like this:
MY_CALL_MACRO("MyMacroName")
|
by: TJ |
last post by:
I'd like to know how the preprocessor treats curly braces, as compared
to how it treats parentheses.
What happens if I pass this:
{ a_function( arg1, arg2, arg3 ) }
as an argument to a function macro? Does it get passed in whole, or
split into smaller parts like so:
|
by: Grande News |
last post by:
Hi, I've got some PHP code that looks like this
$cura= ord($data{$pnum*2});
$curb = ord($data{$pnum*2+1});
Notice the curly braces -- does using them make any difference, or will
square brackets do the same thing?
Thanks
B
|
by: mauricioarango |
last post by:
Hi everybody,
I'm a PHP beginner, so please forgive me for this question.
I am working on code someone else wrote a long time ago. The code was written without curly braces in many places, which for the most has been ok. However I am getting an error message that -for the code snippet I posted below- would read like this:
Notice: Undefined...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it. ...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |