Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #38523 > unrolled thread

Re: Any idea how i can format my output file with ********************Start file*********************** usinf Python 2.7

Started byDave Angel <davea@davea.name>
First post2013-02-09 09:38 -0500
Last post2013-02-09 09:38 -0500
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Any idea how i can format my output file with ********************Start file*********************** usinf Python 2.7 Dave Angel <davea@davea.name> - 2013-02-09 09:38 -0500

#38523 — Re: Any idea how i can format my output file with ********************Start file*********************** usinf Python 2.7

FromDave Angel <davea@davea.name>
Date2013-02-09 09:38 -0500
SubjectRe: Any idea how i can format my output file with ********************Start file*********************** usinf Python 2.7
Message-ID<mailman.1551.1360420708.2939.python-list@python.org>
On 02/09/2013 09:27 AM, Morten Engvoldsen wrote:
> Hi Team,
> I Have saved my output in .doc file and want to format the output with
>
> *************Start the File ************************
>
> Some data here
>
>
> *******************End of File*****************************
>
> Can you let me know how can i do that using Python?
>
>
>

Just add an output statement right after creating the file, and another 
just before closing it.

This is assuming that this is a text file.  By explicitly telling us it 
has a .doc extension, you may be trying to tell us it's in some 
proprietary file format whose type we have to guess.

BTW, if you actually wanted *code*, you might have considered including 
some more information about your environment.  For example a print 
statement is an output statement in Python 2.x, while the print function 
in Python 3.x looks quite different, at least when directed to a file.

-- 
DaveA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web