[Mono-list] Newbie question
jasper van putten
jas_lists@gmx.net
Mon, 12 Aug 2002 02:34:34 +0200 (MEST)
> using System;
> ...
> int partants;
> partants=Console.ReadLine().ToInt32();
> ...
>
> But i get the following error message:
> Pronos.cs(27) error CS0117: `System.String' does not contain a definition
> for `ToInt32'
>
string doesn't contain the ToInt32 methode. it isn't in the ms framework
either.
you can use
partants=int.Parse(Console.ReadLine());
or
partants=System.Convert.ToInt32(Console.ReadLine());
Jasper
--
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net