Contributions
can we generate and perform a Modbus Communication in Test Complete with Python Scripts
Hi All, Have a question reg Modbus Communication. Can we generate and perform a Modbus Communication in Test Complete with Python Scripts. Want to write a Modbus communication code in Python Test Complete scripts and use it to communicate with a PLC. Can it be achieved?874Views0likes2CommentsRe: Unable read excel file with xlrd package
Hi Baxatob: Yes Iam receiving an error AttributeError 'module' object has no attribute 'load_workbook' Error location: Unit: "pythoncode\pythonworks\Script\Unit1" Line: 39 Column: 1. AttributeError 'module' object has no attribute 'load_workbook' THanks for your help adding the python path helps with execution of code. But do i have to install Python in all system where i execute the Test Complete Code. I have few systems with Test Execute and I don't have Python IDLE installed there.5.1KViews0likes1CommentUnable read excel file with xlrd package
Hi: I wrote a code in python to read excel file (.xlsx). Used the import package xlrd. Placed the appropriate package inC:\Program Files (x86)\SmartBear\TestComplete 11\Bin\Extensions\Python\Python34\Lib import xlrd code works fine but Test complete doesnot recognize attribute open_workbook. Code works fine in Python IDLE but Test Complete does not recognize this attribute. def xlrd_package_check(): import xlrd path='C:\\Users\H191725\Desktop\\readwritepython.xlsx' book=xlrd.open_workbook(path) # The above line has issue # print number of sheets Log.message(book.nsheets) # print sheet names message(book.sheet_names()) # get the first worksheet first_sheet = book.sheet_by_index(2) # read a row Log.message(first_sheet.row_values(0)) # read a cell cell = first_sheet.cell(0,0) Log.message(cell) Log.Message(cell.value)5.2KViews0likes4Comments