OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

Could not add dll files while creating an exe from python script using pyinstaller

  • Thread starter Thread starter Saket Khare
  • Start date Start date
S

Saket Khare

Guest
I made a program to connect to IBM DB2 using ibm_db module provided by python. While using import ibm_db, I get this error ImportError: DLL load failed while importing ibm_db: The specified module could not be found.

However, I could resolve this by using **os.add_dll_directory('..\clidriver\bin') **

But when I try to make an executale of this python script, it does not work and gives error as the dll files could not be added to the exe.

I tried making changes to the spec file by entering the dll path in datas but not sure what all changes I need to make.

Can anyone help me what changes I need to make in spec file so that import ibm_db could work.
<p>I made a program to connect to IBM DB2 using ibm_db module provided by python. While using import ibm_db, I get this error
<strong>ImportError: DLL load failed while importing ibm_db: The specified module could not be found</strong>.</p>
<p>However, I could resolve this by using **os.add_dll_directory('..\clidriver\bin') **</p>
<p>But when I try to make an executale of this python script, it does not work and gives error as the dll files could not be added to the exe.</p>
<p>I tried making changes to the spec file by entering the dll path in datas but not sure what all changes I need to make.</p>
<p>Can anyone help me what changes I need to make in spec file so that import ibm_db could work.</p>
 
Top