codetoad.com
  ASP Shopping CartForum & BBS
  - all for $20 from CodeToad Plus!
  
  Home || ASP | ASP.Net | C++/C# | DHTML | HTML | Java | Javascript | Perl | VB | XML || CodeToad Plus! || Forums || RAM 
Search Site:
Search Forums:
  user inputs a space....  sylbaris at 17:45 on Thursday, July 14, 2005
 

I'm running several different fairly low-level programs that ask for a variety of inputs. I've worked out several different methods of testing user inputs for incorrect characters, strings rather than integers, etc., etc. While it may seem unnecessary, I'd like to be prepared for every idiot user that comes along. The program still reacts incorrectly in the following two areas -
If the user inputs control and a character (z or 2 for instance), the program crashes.

If the user inputs anything with a space, the program treats it as two seperate inputs.

While the first error may not be fixable, is there a way around the second? I'm using the standard "cin" command line.

And yes, I'm relatively new to the coding world, so the more details the better.








CodeToad Experts

Can't find the answer?
Our Site experts are answering questions for free in the CodeToad forums
//








Recent Forum Threads
•  Re: Problem with concatenation
•  how to genrates the crystal report by sending a id at runtime
•  help me
•  pls help me with this..
•  Re: Security - Code verify
•  Job @ EarlySail
•  Job @ EarlySail (perl)
•  IPC problem
•  Re: import contacts of msn/yahoo


Recent Articles
ASP GetTempName
Decode and Encode UTF-8
ASP GetFile
ASP FolderExists
ASP FileExists
ASP OpenTextFile
ASP FilesystemObject
ASP CreateFolder
ASP CreateTextFile
Javascript Get Selected Text


© Copyright codetoad.com 2001-2007