• Join/Login
  • Business Software
  • Open Source Software
  • For Vendors
  • Blog
  • About
  • More
    • Articles
    • Create
    • SourceForge Podcast
    • Site Documentation
    • Subscribe to our Newsletter
    • Support Request
SourceForge logo
For Vendors Help Create Join Login
SourceForge logo
Business Software
Open Source Software
SourceForge Podcast
Resources
  • Articles
  • Case Studies
  • Blog
Menu
  • Help
  • Create
  • Join
  • Login
  • Home
  • Browse
  • comtypes
  • Bugs

Returned tuple from COM method doesn't include all outputs

Status: Beta
Brought to you by: cfarrow, jaraco, theller
  • Summary
  • Files
  • Reviews
  • Support
  • Mailing Lists
  • Tickets ▾
    • Feature Requests
    • Bugs
    • Patches
Menu ▾ ▴
  • Create Ticket
  • View Stats

Group

Searches

  • Changes
  • Closed Tickets
  • Open Tickets

Help

  • Formatting Help

#14 Returned tuple from COM method doesn't include all outputs

open
nobody
None
5
2014-02-19
2009-08-12
Anonymous
No

I am accessing SolidWorks via COM using comtypes. I create a new application object as follows:
swApp=comtypes.client.CreateObject('sldworks.application')

To open files with this application, you use the OpenDoc6 method, which is as follows:
ModelDoc2 OpenDoc6(string FileName, int Type, int Options, String Configuration, [Out] int Errors, [Out] int Warnings) (taken from the api help files.

When I call swApp.OpenDoc6, the ModelDoc2 object is not returned. Instead I only get a tuple containing the Errors and Warnings.

I have possible solution, which might not necessarily be all that good:
If I change comtypes/__init__.py line 599 to use rescode (the return from the function) as opposed to outargs, then I get a tuple containing all three outputs. Not sure this would work for all COM libraries.

djm one five eight @ieee.org (where the numbers are really numbers) to ask questions of me.

Discussion

  • Christopher L Farrow

    Christopher L Farrow - 2014-02-19

    Transferred to https://github.com/enthought/comtypes/issues/17 .

     
    If you would like to refer to this comment somewhere else in this project, copy and paste the following link:

Log in to post a comment.

SourceForge
  • Create a Project
  • Open Source Software
  • Business Software
  • Top Downloaded Projects
Company
  • About
  • Team
  • SourceForge Headquarters
    1320 Columbia Street Suite 310
    San Diego, CA 92101
    +1 (858) 422-6466
Resources
  • Support
  • Site Documentation
  • Site Status
  • SourceForge Reviews
SourceForge logo
© 2026 Slashdot Media. All Rights Reserved.
Terms Privacy Opt Out Advertise
×