home *** CD-ROM | disk | FTP | other *** search
/ ftp.tcs3.com / ftp.tcs3.com.tar / ftp.tcs3.com / DRIVERS / Audio / Office2010 / InfoPath.en-us / InfLR.cab / FL_ReadandWritefromtheConsoleWindow_snippe_142546_ENU____.3643236F_FC70_11D3_A536_0090278A1BB8 < prev    next >
Extensible Markup Language  |  2008-09-17  |  2KB  |  42 lines

  1. <?xml version="1.0"?>
  2. <CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  3.   <CodeSnippet Format="1.0.0">
  4.     <Header>
  5.       <Title>Read and Write from the Console Window</Title>
  6.       <Author>Microsoft Corporation</Author>
  7.       <Description>Writes a prompt and then reads in the user request. It is run from a console application.</Description>
  8.       <Shortcut>appConRW</Shortcut>
  9.     </Header>
  10.     <Snippet>
  11.       <Imports>
  12.         <Import>
  13.           <Namespace>Microsoft.VisualBasic</Namespace>
  14.         </Import>
  15.       </Imports>
  16.       <Declarations>
  17.         <Literal>
  18.           <ID>prompt</ID>
  19.           <Type>String</Type>
  20.           <ToolTip>Replace with the input prompt.</ToolTip>
  21.           <Default>"Type in a sentence and hit Enter:"</Default>
  22.         </Literal>
  23.         <Object>
  24.           <ID>inputFromConsole</ID>
  25.           <Type>String</Type>
  26.           <ToolTip>The String variable that stores the input from the console window.</ToolTip>
  27.           <Default>inputFromConsole</Default>
  28.         </Object>
  29.         <Object>
  30.           <ID>outputToConsole</ID>
  31.           <Type>String</Type>
  32.           <ToolTip>The String variable that stores the output to the console window.</ToolTip>
  33.           <Default>outputToConsole</Default>
  34.         </Object>
  35.       </Declarations>
  36.       <Code Language="VB" Kind="method body"><![CDATA[Console.WriteLine($prompt$)
  37. $inputFromConsole$ = Console.ReadLine()
  38. Console.WriteLine($outputToConsole$)
  39. ]]></Code>
  40.     </Snippet>
  41.   </CodeSnippet>
  42. </CodeSnippets>