Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1111999
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T02:38:17+00:00 2026-05-17T02:38:17+00:00

I am programing VIX API from python 2.5, but now I want to port

  • 0

I am programing VIX API from python 2.5, but now I want to port the code to python 3.2

This function opens the virtual machine:

self.jobHandle = self.VixLib.vix.VixVM_Open(self.hostHandle,
                                            "C:\\MyVirtualMachine.vmx", None, None)

Previusly this function is imported from Vix.dll with this code:

vix.VixVM_Open.restype = VixHandle
vix.VixVM_Open.argtypes = [VixHandle,c_char_p,POINTER(VixEventProc),c_void_p]

In 2.5 this code is correct, but in 3.2 it returns ctypes.ArgumentError

What can I do?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T02:38:18+00:00Added an answer on May 17, 2026 at 2:38 am

    Your second argument has to be encoded to a format that the VIX API will understand, since Python 3.x now creates all strings as Unicode. The simplest approach would be to modify your second argument to read:

    "C:\\MyVirtualMachine.vmx".encode('ascii','ignore')
    

    which should give you a variable of type bytes, which should be more palatable to VIX.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Most programing languages have 'include library into your code' function but where is function
I don't have a problem programing to that corner, but I want to know
[Caveat] This is not directly a programing question, but it is something that comes
I recently started reading Programing From The Ground Up (PDF) , but I've run
Hi Masters of Web Programing. I've got this code: <?PHP $db_user = 'user'; $db_pass
I'm new programing in Python, and what I need a little help with this
I'm new to programing, this is my first python-gtk applet and I'm trying to
I am new in programing. I want to save images from Google Images. I
Im very new to C programing, but have limited experience with Python, Java, and
I'm fairly new to C# and WPF programing and right now this problem is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.