Hello
i have this confussion here with the Console.ReadLIne i am trying to read keyboard and then displaying the keyboard entry to the console.
first line is working fine as it has been re written from a book but when i try to implement the other way (Line3) then i am getting error. i was wondering that if there is any other way of reading line from the input buffer.
i remember in c++ i was doing something like
is there something similar to that in C# that i can read the string entered in the above way
I think i have made it clear enough to understand still if there is any confussion then please dono hesitate to ask question.
§ Rented Lips §
----------------
Begning To Learn
----------------
i have this confussion here with the Console.ReadLIne i am trying to read keyboard and then displaying the keyboard entry to the console.
first line is working fine as it has been re written from a book but when i try to implement the other way (Line3) then i am getting error. i was wondering that if there is any other way of reading line from the input buffer.
i remember in c++ i was doing something like
Code:
{
cout >> "enter signal: ";
cin << signal; // where signal is a string
is there something similar to that in C# that i can read the string entered in the above way
Code:
{
Line1 Console.WriteLine("Enter some Signal: ");
Line2 //Signal = Console.ReadLine();
// th above code is working without any problem
// if i remove the '//' of the second line but when
// i try to convert the second line of code
// to then third line of code then the problem occures
// and i get error
Line3 Console.ReadLine(Signal);
Console.WriteLine("You entered: {0}\n", Signal);
}
I think i have made it clear enough to understand still if there is any confussion then please dono hesitate to ask question.
§ Rented Lips §
----------------
Begning To Learn
----------------