The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 Python Worksheet set data not working

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
spconway1987 Posted - 07/09/2015 : 10:45:22 AM
Origin Ver. and Service Release : 2015 (64-bit) Sr2 b0.2.272 (Evaluation)
Operating System: Windows 8

I am using the example from the docs and I'm not sure what I am doing wrong. After executing the code in the screenshot nothing happens. Any help is appreciated. Thanks!
5   L A T E S T    R E P L I E S    (Newest First)
Castiel Posted - 07/09/2015 : 12:00:45 PM
quote:
Originally posted by spconway1987

Thank you very much! I'm curious why does it only work with Python 3.3. Also, why do I need to have 1.0 * x for Python 2.7? Sorry for the follow ups.



No idea. Bug, maybe.

©c¡Ï   ¤È¥¹  ©f¨u©c  ©c¥ì    ¥Î¤³  ©c/     ©¦£¯
 ©c¨Ê¥Î ¤´¥¨  ¥ó ¨×   ¥ó¤á' ¥Ì©¦¥­   /¤í  ¥Õ©¦©f
   ¨Ö             ¦á          ©¦£þ  ©` ¥Õ   ©¦
                              ©¦
spconway1987 Posted - 07/09/2015 : 11:22:06 AM
quote:
Originally posted by cdrozdowski111

Hello,

That code runs with Python 3.3.

Also when running in the Script Window, you have to execute one line at a time. To execute multiple lines, put them in a .py file and call it from Origin using the documented mechanisms.


~Chris



If you select a code block and press enter it will execute the selected code block.
cdrozdowski111 Posted - 07/09/2015 : 11:19:34 AM
Hello,

That code runs with Python 3.3.

Also when running in the Script Window, you have to execute one line at a time. To execute multiple lines, put them in a .py file and call it from Origin using the documented mechanisms.


~Chris
spconway1987 Posted - 07/09/2015 : 11:19:17 AM
Thank you very much! I'm curious why does it only work with Python 3.3. Also, why do I need to have 1.0 * x for Python 2.7? Sorry for the follow ups.
Castiel Posted - 07/09/2015 : 11:13:57 AM
quote:
Originally posted by spconway1987

Origin Ver. and Service Release : 2015 (64-bit) Sr2 b0.2.272 (Evaluation)
Operating System: Windows 8

I am using the example from the docs and I'm not sure what I am doing wrong. After executing the code in the screenshot nothing happens. Any help is appreciated. Thanks!



You may use Python 3.3 instead of Python 2.7.
Or pArr = [[1.0 * x for x in range(5)] for x in range(2)]

©c¡Ï   ¤È¥¹  ©f¨u©c  ©c¥ì    ¥Î¤³  ©c/     ©¦£¯
 ©c¨Ê¥Î ¤´¥¨  ¥ó ¨×   ¥ó¤á' ¥Ì©¦¥­   /¤í  ¥Õ©¦©f
   ¨Ö             ¦á          ©¦£þ  ©` ¥Õ   ©¦
                              ©¦

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000