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
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Python Worksheet set data not working
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

spconway1987

11 Posts

Posted - 07/09/2015 :  10:45:22 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
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!

Castiel

343 Posts

Posted - 07/09/2015 :  11:13:57 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
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)]

妾+   午旦  妹罕妾  妾伊    用仇  妾/     岫ㄞ
 妾京用 仍巨  件 侈   件戶' 甘岫平   /欠  白岫妹
   併             艮          岫  奈 白   岫
                              岫
Go to Top of Page

spconway1987

11 Posts

Posted - 07/09/2015 :  11:19:17 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
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.
Go to Top of Page

cdrozdowski111

USA
247 Posts

Posted - 07/09/2015 :  11:19:34 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
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
Go to Top of Page

spconway1987

11 Posts

Posted - 07/09/2015 :  11:22:06 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
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.
Go to Top of Page

Castiel

343 Posts

Posted - 07/09/2015 :  12:00:45 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
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.

妾+   午旦  妹罕妾  妾伊    用仇  妾/     岫ㄞ
 妾京用 仍巨  件 侈   件戶' 甘岫平   /欠  白岫妹
   併             艮          岫  奈 白   岫
                              岫
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000