Pages: [1]   Go Down
Author Topic: String library problem  (Read 595 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I can't get the String library to work, even declaring an instance of Sting class, like this:

Code:
#include <String.h>
String str = String(10);

Throws this compiler error:
Code:
error: 'string' does not name a type

I've tried compiling the examples that come with the library, and (after fixing the include from WString.h to String.h), they have the same problem.
Any ideas?
Logged

0
Offline Offline
Full Member
***
Karma: 1
Posts: 170
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
(after fixing the include from WString.h to String.h)

If you switch it back, it compiles no problem.

Even though the library is called "String", the actually file names are called "WString".  

Good luck!
« Last Edit: December 27, 2009, 12:07:35 pm by Kitep » Logged

Pages: [1]   Go Up
Jump to: