ROBOTC.net forums
http://robotc.net/forums/

Strings
http://robotc.net/forums/viewtopic.php?f=1&t=5919
Page 1 of 1

Author:  roboRed [ Sun Jun 02, 2013 8:40 pm ]
Post subject:  Strings

Hi,

What's wrong with this code?
Code:
string messageletters[7];
messsageletters[0] = "m";
messsageletters[1] = "e";
messsageletters[2] = "s";
messsageletters[3] = "s";
messsageletters[4] = "a";
messsageletters[5] = "g";
messsageletters[6] = "e";



I got these errors:

**Error**:Undefined variable 'messsageletters'. 'short' assumed.
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].
**Error**:LValue for '[]' operator must be a pointer
**Error**:'[]' operator requires pointer value on left hand side [2].


Thanks :?

Author:  NeXT-Generation [ Sun Jun 02, 2013 9:32 pm ]
Post subject:  Re: Strings

You put three "s" in the part where you assign the variable values. :P

Author:  roboRed [ Sun Jun 02, 2013 9:35 pm ]
Post subject:  Re: Strings

Thank you!

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/