Thread Subject:
fprintf - printing single quotes

Subject: fprintf - printing single quotes

From: patrick hull

Date: 1 May, 2013 13:05:07

Message: 1 of 2

I am attempting to print a line to a txt file:

'output','txt','E:\Temp\'

the printed text needs to include the single quotes. Is there anyway to do this with fprintf?

Subject: fprintf - printing single quotes

From: Steven_Lord

Date: 1 May, 2013 13:27:53

Message: 2 of 2



"patrick hull" <pabaholic.nospam@yahoo.com> wrote in message
news:klr3u2$381$1@newscl01ah.mathworks.com...
> I am attempting to print a line to a txt file:
>
> 'output','txt','E:\Temp\'
>
> the printed text needs to include the single quotes. Is there anyway to
> do this with fprintf?

fprintf('It''s easy to include quotes in an FPRINTed string; use two.\n')

--
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Tags for this Thread

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

rssFeed for this Thread

Contact us