Click here to Skip to main content
15,888,733 members
Home / Discussions / C#
   

C#

 
QuestionIs params a C# keyword? Pin
monrobot1313-Jun-03 12:54
monrobot1313-Jun-03 12:54 
AnswerRe: Is params a C# keyword? Pin
leppie13-Jun-03 13:14
leppie13-Jun-03 13:14 
GeneralOwner-Drawn Scrollbars Pin
J. Dunlap13-Jun-03 12:28
J. Dunlap13-Jun-03 12:28 
GeneralRe: Owner-Drawn Scrollbars Pin
J. Dunlap13-Jun-03 13:55
J. Dunlap13-Jun-03 13:55 
Generalgui event handling Pin
zuhx13-Jun-03 10:08
zuhx13-Jun-03 10:08 
GeneralRe: gui event handling Pin
Paresh Gheewala13-Jun-03 11:22
Paresh Gheewala13-Jun-03 11:22 
Questiondefault (optional) parameters in a function??? Pin
CherezZaboro13-Jun-03 10:06
CherezZaboro13-Jun-03 10:06 
AnswerRe: default (optional) parameters in a function??? Pin
leppie13-Jun-03 10:50
leppie13-Jun-03 10:50 
I think you want to try VB rather Poke tongue | ;-P

No, seriously, C# does NOT support default (optional) parameters. That is generally done with method overloading (a bit boring sometimes, but it does help in other areas, eg complex initialization/ops).

Another option is to variable arguments ak params (like the Console.WriteLine() overload), but that is more similar to var_args in C. In fact the compiler will generate 3 overloads for you, and the "default" array parameter.

<a TITLE="See my user info" href=http://www.codeproject.com/script/profile/whos_who.asp?id=38829>leppie<a>::<a TITLE="Go to all articles  written by me" href=http://www.codeproject.com/script/articles/list_articles.asp?userid=38829>AllocCPArticle</a>(<a TITLE="Go to my latest, greatest article!" href=http://www.codeproject.com/useritems/dfamachine.asp >Generic DFA State Machine for .NET</a>);

GeneralC# Language question for a guru Pin
albean13-Jun-03 9:49
albean13-Jun-03 9:49 
GeneralRe: C# Language question for a guru Pin
J. Dunlap13-Jun-03 10:36
J. Dunlap13-Jun-03 10:36 
GeneralOleDbCommands and OleDbDataAdapter Pin
mindfuck13-Jun-03 4:17
mindfuck13-Jun-03 4:17 
GeneralRe: OleDbCommands and OleDbDataAdapter Pin
Laimis13-Jun-03 5:35
Laimis13-Jun-03 5:35 
GeneralText File Reading Newbie Question Pin
Ricardo Kirkner13-Jun-03 3:45
Ricardo Kirkner13-Jun-03 3:45 
GeneralRe: Text File Reading Newbie Question Pin
Jim Stewart13-Jun-03 5:07
Jim Stewart13-Jun-03 5:07 
GeneralRe: Text File Reading Newbie Question Pin
Ricardo Kirkner13-Jun-03 6:20
Ricardo Kirkner13-Jun-03 6:20 
GeneralRe: Text File Reading Newbie Question Pin
Nick Parker13-Jun-03 8:25
protectorNick Parker13-Jun-03 8:25 
GeneralRe: Text File Reading Newbie Question Pin
dynamic13-Jun-03 15:23
dynamic13-Jun-03 15:23 
GeneralRe: Text File Reading Newbie Question Pin
leppie13-Jun-03 16:31
leppie13-Jun-03 16:31 
GeneralRe: Text File Reading Newbie Question Pin
dynamic13-Jun-03 23:16
dynamic13-Jun-03 23:16 
Questioncomponet for INTERNET EXPLORER programming in .NET? Pin
Asim N.13-Jun-03 3:03
Asim N.13-Jun-03 3:03 
AnswerRe: componet for INTERNET EXPLORER programming in .NET? Pin
Jon Newman14-Jun-03 8:12
Jon Newman14-Jun-03 8:12 
GeneralDouble Buffer - The best way Pin
aeros13-Jun-03 2:46
aeros13-Jun-03 2:46 
GeneralRe: Double Buffer - The best way Pin
James T. Johnson14-Jun-03 3:59
James T. Johnson14-Jun-03 3:59 
GeneralRe: Double Buffer - The best way Pin
Arun Bhalla18-Jun-03 13:41
Arun Bhalla18-Jun-03 13:41 
Questionhow can i handle the column resize event in C# ?? Pin
hard_coder13-Jun-03 2:24
hard_coder13-Jun-03 2:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.