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 for Programming
 Forum for Python
 Connector attribute not available in originpro err

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
bharath2k4er Posted - 01/08/2023 : 12:47:24 PM
Hi,
I am using originpro 2021 version. I am executing sample python program to import an excel sheet in origin. I am getting the following error.
https://www.originlab.com/doc/python/Examples/Worksheet --> Import CSV with Selected Rows
dc = op.Connector(wks)
AttributeError: module 'originpro' has no attribute 'Connector'


when i checked the attributes of originpro, i don't see "Connector" attribute. I have upgraded my originpro package and i still don't see it. However, i see the class "Connector"

attributes = dir(op)

['Axis', 'BaseLayer', 'BaseObject', 'BasePage', 'DBook', 'DSheet', 'GLayer', 'GPage', 'Label', 'List', 'MBook', 'MSheet', 'PATHSEP', 'Plot', 'Union', 'WBook', 'WSheet', '__all__', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__path__', '__spec__', 'active_obj', 'base', 'basename', 'check_convert_py_time_to_tdlt', 'color_col', 'config', 'date', 'dirname', 'dt', 'exit', 'file_dialog', 'find_book', 'find_graph', 'find_sheet', 'from_series', 'get_file_ext', 'get_file_parts', 'get_lt_str', 'get_page', 'get_show', 'glob', 'graph', 'graph_list', 'isfile', 'join', 'last_backslash', 'load_book', 'lt_exec', 'lt_float', 'lt_int', 'make_DataRange', 'matrix', 'modules', 'new', 'new_book', 'new_graph', 'new_sheet', 'np', 'ocolor', 'oext', 'open', 'origin_class', 'os', 'path', 'po', 'project', 'save', 'set_lt_str', 'set_lt_var', 'set_show', 'tdlt', 'time', 'to_rgb', 'utils', 'wait', 'worksheet']

Same happens to some of the other sample codes.


( model = op.NLFit('Gaussian')
AttributeError: module 'originpro' has no attribute 'NLFit')

Operating System:Windows
Pls help.
1   L A T E S T    R E P L I E S    (Newest First)
cpyang Posted - 01/08/2023 : 3:52:25 PM
Support for Connector was added after 2021b, so you need at Origin 2022 or later to use the connector class.

CP

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