Announcement

Collapse
No announcement yet.

Keypad Character Limit

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Keypad Character Limit

    Does anyone happen to know what the character limit is on the ST2 keypads? I am displaying the names of the songs and if they get too long, it changes to a bunch of Chinese characters. I would like to script out and cut off the end of the string if it is beyond the limit... oh and if someone could also help with the code that is needed to drop the last part of a string, that would be helpful as well.

    #2
    I'm not sure about the max length on the displays, but for when you find that out, you can use the left method:

    Code:
    Dim TestString As String = "Hello World!"
    ' Returns "Hello".
    Dim subString As String = Left(TestString, 5)
    Great thing about left() is that if you put 20 for the length, but your string is 15 characters long, it won't fail. it will just return the 15.

    edit: the above is for vb.net, which I assumed you are using. There is a c#.net equivalent as well, just a few semantic differences.

    Comment


      #3
      Thanks Frank and I think my google skills finally worked as I found that it appears the limit is 38 characters.

      Comment

      Working...
      X