|
From: | Søren Hauberg |
Subject: | Re: sscanf parameter size = Inf |
Date: | Wed, 18 Jul 2007 13:08:08 +0200 |
User-agent: | Thunderbird 1.5.0.12 (X11/20070604) |
address@hidden skrev:
Hi allI searched in the archives (nabble) for this problem, but I couldn't founda solution. I tried to read an unknown amount of numers in a text line with sscanf, but it returns only the first number.. example: ======= strLine = fgetl(fid); ## strLine e.g.: "1.2345 2.1345 3.1234 5.1234" ## delimiter is a simple space sign! [vals count] = sscanf(strLine,"%f","Inf");
You should write "Inf" as a string, so your last line should look like this: [vals count] = sscanf(strLine,"%f",Inf); Søren
[Prev in Thread] | Current Thread | [Next in Thread] |