Guest User

Untitled

a guest
Nov 26th, 2015
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. $s = "Das ist ""ein"" Test!"
  2. $s_ = 'Das ist ''ein'' Test!'
  3. $s__ = 'Das ist "ein" Test!'
  4. $s___ = "Das ist 'ein' Test!"
  5.  
  6. MsgBox(0,0, _ClearString($s) & @CRLF & _
  7. _ClearString($s_) & @CRLF & _
  8. _ClearString($s__) & @CRLF & _
  9. _ClearString($s___))
  10.  
  11. Func _ClearString($strWert)
  12. Local $strChars = "-.,:;#+ß'*?=)(/&%$§!~\}][{`´_" & '"'
  13. For $i = 1 To StringLen($strChars)
  14. $strWert = StringReplace($strWert, StringMid($strChars, $i, 1), "")
  15. Next
  16. Return $strWert
  17. EndFunc
  18.  
  19. #cs Output
  20. Das ist ein Test!
  21. Das ist ein Test!
  22. Das ist ein Test!
  23. Das ist ein Test!
  24. #ce
Advertisement
Add Comment
Please, Sign In to add comment