Path: news.mathworks.com!not-for-mail
From: "us " <us@neurol.unizh.ch>
Newsgroups: comp.soft-sys.matlab
Subject: Re: extracting data from long message
Date: Thu, 2 Aug 2007 21:05:29 +0000 (UTC)
Organization: Universit&#228;tsSpital Z&#252;rich
Lines: 18
Message-ID: <f8tguo$cs$1@fred.mathworks.com>
References: <f8tb9v$mmp$1@fred.mathworks.com> <f8tf3o$huk$1@canopus.cc.umanitoba.ca> <f8tgb5$can$1@fred.mathworks.com>
Reply-To: "us " <us@neurol.unizh.ch>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1186088729 412 172.30.248.38 (2 Aug 2007 21:05:29 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 2 Aug 2007 21:05:29 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 11
Xref: news.mathworks.com comp.soft-sys.matlab:422252


Bill Jordan:
<SNIP down to typo...

> > submessages = textscan(MSG, '%s', 'Delimeter', ':')
> I get the message "??? Error using ==> textscan
> First input must be of type double."...

because, this should have read

     msg='12.34 05/06/06 : cg: ng';
     sm=textscan(msg,'%s','Delimiter',':'); % <- typo
     sm{:}
% ans = 
%    '12.34 05/06/06 '
%    'cg'
%    'ng'

us