home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 9,285 of 10,840   
   Raoul Watson to All   
   Re: Look For CR in Text Data   
   12 Mar 05 14:22:31   
   
   From: WatsonR@IntelligenCIA.com   
      
   "Stephen Saunders"  wrote in message   
   news:6pCYd.1661$qW.357@newsread3.news.atl.earthlink.net...   
   > Hey Folks,   
   > This doesn't find the CR because CStr(13) equals a two character string   
   > ("13")   
   >   
      
   Try this Steve..   
      
   Put a text box and label on a form and a command button:   
      
   Private Sub Command1_Click()   
   Dim t$   
   Dim x   
   t$ = Text1.Text   
      
   x = InStr(t$, Chr$(13))   
   If x > 0 Then   
      Label1.Caption = "CR found at pos " & x   
   Else   
      Label1.Caption = "No CR found"   
   End If   
      
   End Sub   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca