Click here to Skip to main content
15,907,497 members
Home / Discussions / C#
   

C#

 
QuestionDiffernce between private readonly fields and non private readonly fields Pin
DJ24523-Apr-09 20:44
DJ24523-Apr-09 20:44 
AnswerRe: Differnce between private readonly fields and non private readonly fields Pin
Ashfield23-Apr-09 20:51
Ashfield23-Apr-09 20:51 
AnswerRe: Differnce between private readonly fields and non private readonly fields Pin
CPallini23-Apr-09 21:41
mveCPallini23-Apr-09 21:41 
AnswerRe: Differnce between private readonly fields and non private readonly fields Pin
PIEBALDconsult24-Apr-09 3:53
mvePIEBALDconsult24-Apr-09 3:53 
Questionhow to read pdf file.... Pin
raj23136223-Apr-09 20:16
raj23136223-Apr-09 20:16 
AnswerRe: how to read pdf file.... Pin
Christian Graus23-Apr-09 20:26
protectorChristian Graus23-Apr-09 20:26 
GeneralRe: how to read pdf file.... Pin
raj23136223-Apr-09 20:39
raj23136223-Apr-09 20:39 
AnswerRe: how to read pdf file.... [modified] Pin
tom57200723-Apr-09 22:09
tom57200723-Apr-09 22:09 
GeneralRe: how to read pdf file.... Pin
raj23136223-Apr-09 22:39
raj23136223-Apr-09 22:39 
AnswerRe: how to read pdf file.... Pin
tom57200723-Apr-09 23:52
tom57200723-Apr-09 23:52 
GeneralRe: how to read pdf file.... Pin
raj23136224-Apr-09 0:05
raj23136224-Apr-09 0:05 
QuestionShow progress bar Pin
Yogesh Tayade23-Apr-09 20:10
Yogesh Tayade23-Apr-09 20:10 
AnswerRe: Show progress bar Pin
Christian Graus23-Apr-09 20:12
protectorChristian Graus23-Apr-09 20:12 
QuestionCookies storing Problem in C# Pin
gopinathtamil23-Apr-09 19:49
gopinathtamil23-Apr-09 19:49 
QuestionPublish : Setup is not working on client machine Pin
ddravin200023-Apr-09 19:33
ddravin200023-Apr-09 19:33 
AnswerRe: Publish : Setup is not working on client machine Pin
Abhijit Jana23-Apr-09 20:04
professionalAbhijit Jana23-Apr-09 20:04 
GeneralRe: Publish : Setup is not working on client machine Pin
ddravin200023-Apr-09 20:54
ddravin200023-Apr-09 20:54 
Questionretrive image local path from web handler Pin
LiYS23-Apr-09 17:20
LiYS23-Apr-09 17:20 
AnswerRe: retrive image local path from web handler Pin
Christian Graus23-Apr-09 20:22
protectorChristian Graus23-Apr-09 20:22 
QuestionHow To Capture The Whole ClientZone Of Window With The Scroll Pin
wangxuekong23-Apr-09 16:19
wangxuekong23-Apr-09 16:19 
QuestionHttpWebRequest and HttpWebResponse Pin
AndieDu23-Apr-09 15:25
AndieDu23-Apr-09 15:25 
QuestionAny news when LINQ be able to talk to Oracle/MySQL Pin
devvvy23-Apr-09 15:05
devvvy23-Apr-09 15:05 
QuestionOperator | | Pin
ctreed72823-Apr-09 13:38
ctreed72823-Apr-09 13:38 
Hi everyone. I'm new here and new to using C# coding as well so any help would be greatly apprectiated! I am trying to build my program but this message keeps popping up: Operator '||' cannot be applied to operands of type 'bool' and 'string'

I have tried everything that I know. Please help! The code is below:



using System;

namespace Program13
{
class StateAbbreviations
{
public static void Main( )
{
string stateabb;


Console.WriteLine("Enter all of the following state abbreviations: NC, AL, GA, FL, OH");
stateabb = Console.ReadLine();

Console.WriteLine("\n");


if (stateabb == "NC" || "nc")
Console.WriteLine("North Carolina");
else if (stateabb == "AL" || "al")
Console.WriteLine("Alabama");
else if (stateabb == "GA" || "ga")
Console.WriteLine("Georgia");
else if (stateabb == "FL" || "fl")
Console.WriteLine("Florida");
else if (stateabb == "OH" || "oh")
Console.WriteLine("Ohio");

else Console.WriteLine("Not one of the selected states");


}
}
}

AnswerRe: Operator | | Pin
Luc Pattyn23-Apr-09 14:59
sitebuilderLuc Pattyn23-Apr-09 14:59 
GeneralRe: Operator | | Pin
ctreed72823-Apr-09 15:17
ctreed72823-Apr-09 15:17 

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.