On 09Aug2019 20:53, Paul St George wrote:
I almost understand.
Are you saying I should change the first line of code to something
like:
|outstream = with open(path to my file,'w') # this is invalid syntax|
and then delete the
outstream.close()
No, you should do what Peter wrote:
with open
On 09/08/2019 15:59, Rhodri James wrote:
On 09/08/2019 14:54, Paul St George wrote:
On 09/08/2019 04:09, Cameron Simpson wrote:
On 08Aug2019 22:42, Paul St George wrote:
On 08/08/2019 10:18, Peter Otten wrote:
The print() function has a keyword-only file argument. So:
with open(..., "w") a
On 09/08/2019 14:54, Paul St George wrote:
On 09/08/2019 04:09, Cameron Simpson wrote:
On 08Aug2019 22:42, Paul St George wrote:
On 08/08/2019 10:18, Peter Otten wrote:
The print() function has a keyword-only file argument. So:
with open(..., "w") as outstream:
print("Focal length:", bpy
On 09/08/2019 04:09, Cameron Simpson wrote:
On 08Aug2019 22:42, Paul St George wrote:
On 08/08/2019 10:18, Peter Otten wrote:
The print() function has a keyword-only file argument. So:
with open(..., "w") as outstream:
print("Focal length:", bpy.context.object.data.lens,
file=outstream)
On 08Aug2019 22:42, Paul St George wrote:
On 08/08/2019 10:18, Peter Otten wrote:
The print() function has a keyword-only file argument. So:
with open(..., "w") as outstream:
print("Focal length:", bpy.context.object.data.lens, file=outstream)
[...]
That worked perfectly.
outstream = o
On 08/08/2019 10:18, Peter Otten wrote:
Paul St George wrote:
I am using Python 3.5 within Blender. I want to collect values of the
current settings and then write all the results to a file.
I can see the settings and the values in the Python console by doing
this for each of the settings
|
|
Paul St George wrote:
> I am using Python 3.5 within Blender. I want to collect values of the
> current settings and then write all the results to a file.
>
> I can see the settings and the values in the Python console by doing
> this for each of the settings
> |
> |
>
> |print(“Focal length:”,b