Quantcast
Viewing all articles
Browse latest Browse all 5

switch case help

I keep on receiving this error " The name 'Liverpool' does not exist in the current context "
May I know how can I solve this and why cause the problem.
This is part of my code.
Thank You

 

privatevoid btnShow_Click(object sender, EventArgs e)

{

 

string strChampion;

strChampion =

Convert.ToString(txtChampion.Text);

 

switch (strChampion)

{

 

case Liverpool:

 

MessageBox.Show("YOU ARE SO SMART AS THEY ARE THIS SEASON EPL,CHAMPOIN LEAGUE, FA CUP AND CARLING CUP CHAMPION");

 

break;


Viewing all articles
Browse latest Browse all 5

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>