Click here to Skip to main content
15,887,683 members
Home / Discussions / C#
   

C#

 
AnswerRe: Logon with UserName and Password Pin
ChrisKo17-Sep-07 12:33
ChrisKo17-Sep-07 12:33 
QuestionRe: Logon with UserName and Password Pin
T4AMD17-Sep-07 12:42
T4AMD17-Sep-07 12:42 
AnswerRe: Logon with UserName and Password Pin
ChrisKo17-Sep-07 12:50
ChrisKo17-Sep-07 12:50 
AnswerRe: Logon with UserName and Password Pin
PIEBALDconsult17-Sep-07 14:01
mvePIEBALDconsult17-Sep-07 14:01 
QuestionConsole application keypress Pin
ballzinator17-Sep-07 11:50
ballzinator17-Sep-07 11:50 
AnswerRe: Console application keypress Pin
ChrisKo17-Sep-07 12:27
ChrisKo17-Sep-07 12:27 
GeneralRe: Console application keypress Pin
ballzinator18-Sep-07 3:27
ballzinator18-Sep-07 3:27 
GeneralRe: Console application keypress Pin
Big Daddy Farang18-Sep-07 8:22
Big Daddy Farang18-Sep-07 8:22 
That makes it a little tougher. Which version of .NET are you using? The Console.ReadKey() that Chris suggested is not available until 3.0, unfortunately.

Seems to me that you'll want to make frequent checks for "escape key pressed" within your infinite loop. Some pseudo-code:
while (true)
{
  flag = false
  get next file
  open file
  while (not flag)
  {
    read line from file
    if eof
      flag = true
    else
    {
      process data from file
      if escape key pressed
        flag = true
    }
  }
  close file
  if flag
    exit program
}

The big problem remaining is how to determine if the escape key has been pressed. If you're using 3.0 then Console.ReadKey() should do it. If not, well does it have to be the escape key? The enter key would a lot easier to detect: Console.ReadLine().

BDF
Questionwhat is better c# or vb.net ?? Pin
sofy200817-Sep-07 11:49
sofy200817-Sep-07 11:49 
AnswerRe: what is better c# or vb.net ?? Pin
Matthew Cuba17-Sep-07 12:42
Matthew Cuba17-Sep-07 12:42 
AnswerRe: what is better c# or vb.net ?? Pin
Patrick Etc.17-Sep-07 13:33
Patrick Etc.17-Sep-07 13:33 
GeneralRe: what is better c# or vb.net ?? Pin
PIEBALDconsult17-Sep-07 13:58
mvePIEBALDconsult17-Sep-07 13:58 
GeneralRe: what is better c# or vb.net ?? Pin
Luc Pattyn17-Sep-07 14:41
sitebuilderLuc Pattyn17-Sep-07 14:41 
AnswerRe: what is better c# or vb.net ?? Pin
BoneSoft17-Sep-07 17:50
BoneSoft17-Sep-07 17:50 
GeneralRe: what is better c# or vb.net ?? Pin
Big Daddy Farang18-Sep-07 8:30
Big Daddy Farang18-Sep-07 8:30 
GeneralRe: what is better c# or vb.net ?? Pin
BoneSoft18-Sep-07 8:51
BoneSoft18-Sep-07 8:51 
AnswerRe: what is better c# or vb.net ?? Pin
PIEBALDconsult17-Sep-07 18:15
mvePIEBALDconsult17-Sep-07 18:15 
AnswerRe: what is better c# or vb.net ?? Pin
Nouman Bhatti17-Sep-07 18:58
Nouman Bhatti17-Sep-07 18:58 
GeneralRe: what is better c# or vb.net ?? Pin
sofy200818-Sep-07 9:18
sofy200818-Sep-07 9:18 
QuestionHow to connect to network printer via C# Pin
coleschuk17-Sep-07 11:07
coleschuk17-Sep-07 11:07 
AnswerRe: How to connect to network printer via C# Pin
zhousz17-Sep-07 17:28
zhousz17-Sep-07 17:28 
AnswerRe: How to connect to network printer via C# Pin
ekynox17-Sep-07 17:35
ekynox17-Sep-07 17:35 
GeneralRe: How to connect to network printer via C# Pin
coleschuk18-Sep-07 3:27
coleschuk18-Sep-07 3:27 
GeneralRe: How to connect to network printer via C# Pin
ekynox14-Nov-07 0:52
ekynox14-Nov-07 0:52 
GeneralRe: How to connect to network printer via C# Pin
Pallavi0024-May-11 19:16
Pallavi0024-May-11 19:16 

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.