How to cut too long word?

Results 1 to 3 of 3

Thread: How to cut too long word?

  1. #1
    Jermu Laine Guest

    Default How to cut too long word?

    When somebody write too long words to text, like "rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr rrrrrrrrrrrrrrrrr"<BR><BR>Any ideas?

  2. #2
    omc Guest

    Default RE: How to cut too long word?

    Where are they writing the word? If it is a textbox you could set a maxlength=15 or whatever size you want so the user can&#039t enter more then 15 (or whatever) characters.<BR><BR>Or you can use VBScript&#039s Mid function:<BR>strFirst="rrrrrrrrrrrrrrrrrrrrrrrrrrr rrrrrrrrrrrrrrrr"<BR>strShortented=mid(strMain, 1, 15)<BR><BR>strShortened will be the first 15 characters.

  3. #3
    Join Date
    Dec 1969
    Posts
    168

    Default RE: How to cut too long word?

    Two possible solutions. Use the "maxlength" property of your input box or do a<BR><BR>if Len(string) &#062; maxlength then string = Left(string, maxlength)<BR><BR>in the recieving end of your code.<BR><BR>Hope this helps...Cheers!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •