From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: GUI comments box
Date: Thu, 6 Dec 2012 17:07:08 +0000 (UTC)
Organization: GMO LLC
Lines: 10
Message-ID: <k9qjbs$269$>
References: <k9qfi0$gcj$>
Reply-To: <HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: 1354813628 2249 (6 Dec 2012 17:07:08 GMT)
NNTP-Posting-Date: Thu, 6 Dec 2012 17:07:08 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 2383542
Xref: comp.soft-sys.matlab:784333

"Chris McCorquodale" wrote in message <k9qfi0$gcj$>...
> I am writing a gui that requires a 'comments' box for users to allow them to make comments/notes etc before saving or printing.
> Initially I thought this would be easy - a big edit box. But that doesn't work as it only allows writing on one line. Also when you run out of room, it doesn't move on to the next line, just goes off the end.

Try using inputdlg(), specifying the number of lines as the 3rd argument. E.g. to show an input dialog with 10 lines:

res = inputdlg('Enter Comment','Comment',10)