SC4 Devotion Forum Archives

Sim City 4 Devotion Tools => Tools - General Discussion => SC4PIM (PIM-X/X-Tool) => Topic started by: CasperVg on January 03, 2012, 10:27:01 PM

Title: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on January 03, 2012, 10:27:01 PM
PIM-X Windows 7 SP1 Bug - Fixed!

Hi everyone,

I managed to track down the problem to a single file used by PIM-X (and also other Python-based  applications, by the way) that somehow becomes corrupted with Windows 7 SP1.
As a result, PIM-X failed to load under Win7 SP1, producing a load of error reports instead.

However, replacing the file named "multiarray.pyd" in the PIM-X Program Files directory with an identical, but recompiled version solves the problem completely, as it removes the corruption, so PIM-X will load once again!

An official patch for PIM-X on Win7 SP1 will be released soon on the LEX, but in the meantime I have attached the file below.

Install Instructions
1. Unzip the attached file
2. Place the file named 'multiarray.pyd' in your C:\Program Files\SC4PIM directory (or C:\Program Files (x86)\SC4PIM if you're on a 64-bit system)
3. If it asks to overwrite the old file, click YES.
4. That's it, you should be able to run SC4PIM flawlessly now!

F.A.Q.
1. Do I need this patch if I'm using Windows Vista, Windows XP or earlier?
--> No, you do not need it if your SC4PIM is working fine. It doesn't contain any new functionality, so I would say "never change a winning team" :)

2. Does this patch work for 64-bit as well as 32-bit systems?
--> Yes, it has been confirmed to work on both 64- and 32-bit setups.

3. My SC4PIM still doesn't work after replacing the file.
--> Feel free to post below or in the PIM-X Official Support Thread if you still experience any malfunctioning, but most likely the problem has a different source.

Of course, also make sure to install the required DLLs, mentioned in the SC4PIM Support Thread (http://sc4devotion.com/forums/index.php?topic=9279.0) to the application directory. Without them, SC4PIM won't work (even with this patch)!

Hope it works for you!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Pat on January 03, 2012, 11:07:20 PM
Hey Casper great catch there man  :thumbsup:
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: FrankU on January 04, 2012, 03:25:09 AM
Hi Casper,

This is really very very good news! Who did find this out? Who is worth receiving at least one karma point?
And also: does this mean there is also a solution to the Terrafromer problems?
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on January 04, 2012, 04:15:54 AM
I have never personally encountered this issue on SC4 Terraformer (it always ran fine on my Win7 SP1 64bit, without changes (same for Datpacker, Cleanitol etc)). But if you're talking about this thread/problem (http://sc4devotion.com/forums/index.php?topic=14141.0). Then yes, it could probably be solved in a similar way. Can you try adding multiarray.pyd to your SC4TF program files directory and see if that solves anything?

Contrary to SC4PIM though, there is no multiarray.pyd in the program folder of SC4TF itself. But the library.zip (which can't be edited afaik) does contain it.


Hope it helps,
Casper
(it was me who found the solutions btw ;)
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: FrankU on January 04, 2012, 04:51:49 AM
Casper,

I must admit I never even tried to open Terraformer since I have my Win7 x64 machine, so I don' t personally bother about this, but Iread here and there that there were problems. Like Brechtje who was making a very detailed map of the northern and soutern Netherlands (meaning Belgium and Netherlands) and who quit, as far as I know, because of this issue.

So maybe I am completely wrong in this matter.  &mmm
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on January 04, 2012, 05:08:09 AM
Well, since the traceback from the bigro's (http://sc4devotion.com/forums/index.php?topic=14141.0) problem with SC4TF:

Traceback (most recent call last):
  File "SC4Terraformer.py", line 4, in ?
  File "SC4TerraformerApp.pyo", line 76, in ?
      File "datReader.pyo", line 8, in ?
      File "Numeric.pyo", line 91, in ?
  ImportError: DLL load failed: The parameter is incorrect.


Is pretty much the same as the error everyone was getting with SC4PIM:

Traceback (most recent call last):
  File "SC4PIM.py", line 1, in ?
  File "SC4PIMApp.pyo", line 117, in ?
  File "SC4IconMakerDlg.pyo", line 7, in ?
  File "SC4Data.pyo", line 2, in ?
  File "S3DReader.pyo", line 2, in ?
  File "S3DViewer.pyo", line 3, in ?
  File "Numeric.pyo", line 91, in ?
  File "multiarray.pyo", line 12, in ?
  File "multiarray.pyo", line 10, in
__loadImportError: DLL load failed: The parameter is incorrect.


Means you might not be wrong on this matter at all.

Clearly, both problems are pretty similar; as both are caused by an incorrect parameter (apparently caused by the multiarray.pyo corruption) and called by Numeric.pyo, a (by now deprecated, according to the interwebs) Python plugin that can handle complex mathematical calculations and matrices, arrays etc. However, the biggest discrepancy between both cases is that SC4PIM worked for no-one once they had installed Win7 SP1, while it seems SC4TF only malfunctions for a select (but still significant) group of users using Win7 SP1 (or even 'vanilla' Win7 ?).

I guess that means we can't be sure wether placing multiarray.pyd in the SC4TF Program Files directory will fix the issues, but it would be worth a shot - so I would like to do a warm request to anyone who's having similar issues with SC4Terraformer: please, try placing multiarray.pyd (available in the thread header) in your SC4TF Program Files folder and report back wether it works.

Greetings,
Casper
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: xannepan on January 04, 2012, 07:21:25 AM
 &apls &apls &apls

Works perfect! Fantastic! Thank you!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: FrankU on January 04, 2012, 12:33:45 PM
Hi Casper,

Clicking on the link gives me a index.php file which is not what I am supposed to receive. Please help!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: catty on January 04, 2012, 12:51:53 PM
Quote from: FrankU on January 04, 2012, 12:33:45 PM
Hi Casper,

Clicking on the link gives me a index.php file which is not what I am supposed to receive. Please help!

There is a bug in the site software, if you have firefox8, then any attachments will download as index.php, firefox7 is fine as is firefox9, you can download it using a different browser
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: vester on January 04, 2012, 01:27:59 PM
Upgrade to Firefox 9 and the problems is gone.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: carlfatal on January 04, 2012, 05:12:42 PM
A big big thank you!  :thumbsup: :thumbsup:

Greetz, Carl
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: FrankU on January 05, 2012, 04:18:57 AM
Quote from: catty on January 04, 2012, 12:51:53 PM
There is a bug in the site software, if you have firefox8, then any attachments will download as index.php, firefox7 is fine as is firefox9, you can download it using a different browser
Quote from: vester on January 04, 2012, 01:27:59 PM
Upgrade to Firefox 9 and the problems is gone.

I just did. It worked. Thanks. Sometimes it is so easy, but hard to find out....
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on January 06, 2012, 12:04:45 AM
Quote from: FrankU on January 05, 2012, 04:18:57 AM
Quote from: catty on January 04, 2012, 12:51:53 PM
There is a bug in the site software, if you have firefox8, then any attachments will download as index.php, firefox7 is fine as is firefox9, you can download it using a different browser
Quote from: vester on January 04, 2012, 01:27:59 PM
Upgrade to Firefox 9 and the problems is gone.

I just did. It worked. Thanks. Sometimes it is so easy, but hard to find out....
Good to see you got it working ;)

I have good news for those who want to use the SC4 Savegame Explorer: the multiarray.pyd fix also works there!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: ScottFTL on January 24, 2012, 07:47:44 PM
This also worked for me.  I cannot thank you enough, Casper!  &apls
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: namspopof on January 28, 2012, 06:19:14 AM
Very BIGGGGGGGG Thanks !!!

PIMX is Back ! &apls &apls
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: gn_leugim on January 28, 2012, 08:11:05 AM
thank you very much :D
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: StephenMotsinger on January 30, 2012, 06:08:19 PM
This FIX WORKED PERFECTLY for me.. THANK YOU SO VERY MUCH!  Stephen
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Ol.S / Benoit on February 17, 2012, 06:02:58 AM
Thanks a lot Casper ! Works perfectly :)
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Cockatoo-210893 on February 17, 2012, 04:27:41 PM
Thanks very much!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Jasoncw on February 18, 2012, 05:11:37 PM
 &apls  &apls  &apls
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Aaron Graham on February 18, 2012, 06:43:15 PM
Thank you guys. :D
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: tcx on February 19, 2012, 12:13:09 PM
thank you!!! :thumbsup:
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Wilfried on April 07, 2012, 12:47:57 AM
This is pefect! Thank you, Casper. :)
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: oyefor on April 27, 2012, 05:45:23 AM
Thanks a LOT! it works now
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: mark on April 27, 2012, 09:19:54 AM
Thanks, now works a treat.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Uzil on June 11, 2012, 04:27:02 PM
A big thank you, it's work fine !  :thumbsup:
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: DolAtoR on June 13, 2012, 09:23:34 AM
Forgot my password but had to reset it just to thank you for your work!  &apls

Your fix helped with the "dll load failed: The parameter is incorrect" bug I had when starting the SC4 Savegame Explorer  (http://sc4devotion.com/csxlex/lex_filedesc.php?lotGET=2021) on Windows 7 SP1.

Guys like you are the reason why I like the SC4 community so much :thumbsup:
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: AgeKay on August 21, 2012, 07:08:52 AM
Brilliant, this worked like a charm!   ;D
Thanks a lot for the fix Casper  :thumbsup:
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: A Nonny Moose on October 04, 2012, 06:19:05 PM
Quote from: CasperVg on January 04, 2012, 04:15:54 AM
I have never personally encountered this issue on SC4 Terraformer (it always ran fine on my Win7 SP1 64bit, without changes (same for Datpacker, Cleanitol etc)). But if you're talking about this thread/problem (http://sc4devotion.com/forums/index.php?topic=14141.0). Then yes, it could probably be solved in a similar way. Can you try adding multiarray.pyd to your SC4TF program files directory and see if that solves anything?

Contrary to SC4PIM though, there is no multiarray.pyd in the program folder of SC4TF itself. But the library.zip (which can't be edited afaik) does contain it.


Hope it helps,
Casper
(it was me who found the solutions btw ;)

Hi Casper.

If you have to edit a .zip, the Archive Manager in Linux can do it.  Just create a (Ubuntu) live CD, and you can use it without installing the O/S simply by booting from the disk.

John.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on October 04, 2012, 09:53:05 PM
Quote from: A Nonny Moose on October 04, 2012, 06:19:05 PM
<snip>

Hi Casper.

If you have to edit a .zip, the Archive Manager in Linux can do it.  Just create a (Ubuntu) live CD, and you can use it without installing the O/S simply by booting from the disk.

John.

Heh, that's not a bad idea. I'll definitely check that out. I already dualboot Ubuntu (need it for my CompSci classes) but hadn't thought of using the archive manager to do it.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: NCGAIO on October 05, 2012, 03:52:25 AM

I even had a curiosity to ask why this moose was never here ...
Glad to know that the link has brought you to a subject to post.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: requested on October 29, 2012, 01:01:20 AM
Hey folks!
I just wanted to thank you for the bugfix, works like a charm now. Now I just need to figure out how to use it^^
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: noahclem on December 28, 2012, 06:56:52 AM
It does work, thanks!!!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: BarbyW on January 16, 2013, 11:55:46 AM
Thanks for the fix, Casper. I hadn't tried to run SC4PIM since I installed SP1 so when it wouldn't start up I looked here. It works properly now.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: bwhitejr on January 31, 2013, 11:26:28 AM
I may be stupid but I can not find the bug-fix file. It does not appear to be attached to this forum. Am I missing something?
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: bwhitejr on January 31, 2013, 11:45:01 AM
I guess I am stupid :).   Just after sending the above question I found the file. I installed it, and it works!  Thanks anyway.  My next problem is install the Maxis Building Architect Tool.  Though I put it in the SC4 Directory, I am told it can't find SimCity.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: docj101 on May 10, 2013, 10:54:27 PM
I am running Win8 64bit.  I was getting this error when starting PIMx:

QuoteTraceback (most recent call last):
  File "SC4PIM.py", line 1, in ?
  File "SC4PIMApp.pyo", line 96, in ?
  File "wx\__init__.pyo", line 45, in ?
  File "wx\_core.pyo", line 4, in ?
  File "wx\_core_.pyo", line 12, in ?
  File "wx\_core_.pyo", line 10, in __load
ImportError: DLL load failed: The specified module could not be found.

I tried putting the new multiarray.pyd file into my SC4PIM folder and it didn't change my results. 

I changed my compatibility settings to: run in compatibility mode for 'WinXP (service pack 2)' and 'run program as administrator', now the program works perfectly again. 

Just thought I would mention this in case somebody else forgot about compatibility settings like I had momentarily.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: rajwarrior on July 19, 2014, 03:03:33 PM
Finally got PIM-X to work, THANK YOU!!! Now, if the LEX download would only include the fix (or at least direct you to the fix!)
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on July 20, 2014, 10:57:38 AM
You're right, rajwarrior. I've added a link to the bugfix in the PIM-X LEX description and comment section so that people with this issue will find the solution more quickly in the future
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Gondracorn on August 30, 2014, 03:29:51 AM
I got this error when moving the files:

Traceback (most recent call last):
  File "SC4PIMApp.pyo", line 3136, in OnBeginDrag
  File "SC4Data.pyo", line 50, in __getitem__
KeyError

I don't know why this is happening. I tried Running in Compatability mode and as Administrator.

I'll try to add parameters and see if it helps.

I will get back to you soon
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Gondracorn on August 30, 2014, 03:41:21 AM
Quote from: Gondracorn on August 30, 2014, 03:29:51 AM
I got this error when moving the files:

Traceback (most recent call last):
  File "SC4PIMApp.pyo", line 3136, in OnBeginDrag
  File "SC4Data.pyo", line 50, in __getitem__
KeyError

I don't know why this is happening. I tried Running in Compatability mode and as Administrator.

I'll try to add parameters and see if it helps.

I will get back to you soon

Appears any parameters don't change a thing. Something's wrong with these files. I'm on Windows 8 Pro 64 bit
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: vortext on August 30, 2014, 04:40:28 AM
More likely you're doing something that's not possible, e.g. make a rci desc out of a prop desc. Perhaps you could provide some more info what you were doing and with which files. 
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: CasperVg on August 30, 2014, 05:13:31 AM
I think vortext is right, you may just be trying to perform an action (dragging a file somewhere?) where PIM-X doesn't support it.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: Gondracorn on August 30, 2014, 06:18:20 AM
I'm Trying To Drag a File called CO$$$30_4NYBuilding1_0577 from the CO$$$30x22_5_5000008C in the Named Families (Families) Folder to the Jail Folder.

Is this right? Or am I doing something wrong?

I'm trying to create a ploppable jail custom lot with this file.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: vortext on August 30, 2014, 06:26:46 AM
yeah, that's not gonna work. You need to look up the actual building model at the top and drag it to the jail category. See Creating the Building Exemplar from a BAT Model (http://sc4devotion.com/forums/index.php?topic=2306.msg68209#msg68209). Even though in your case it's not a growable you're after, the principle is the same for creating jail, or a school, or, well, any kind of building really. 
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: vester on August 30, 2014, 06:36:58 AM
Quote from: Gondracorn on August 30, 2014, 06:18:20 AM
I'm Trying To Drag a File called CO$$$30_4NYBuilding1_0577 from the CO$$$30x22_5_5000008C in the Named Families (Families) Folder to the Jail Folder.

Is this right? Or am I doing something wrong?

I'm trying to create a ploppable jail custom lot with this file.

Please use the right thread:     
PIMX Official support thread (http://sc4devotion.com/forums/index.php?topic=9279.320)
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: tfinvold on August 31, 2014, 08:05:49 PM
The bug fix included in here seems to point to exactly that file as the problem even though I already replaced the file with your current file... I first had a wazoo of random bugs and the program would never actually start and still doesn't but now I get this error screen.. See attachment below... ()what()
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: v7012 on December 03, 2014, 04:48:07 AM
Hi people, I don't know why but I still can't start the PIM !! ...  ()sad() :'(
I think I did what I have to do, I downloaded the PIM itself ( &apls ), then I downloaded the update v1.0, and then the file for fixing the bug in this discussion.

BUT! still nothing when I try to open it. I tried to put it in compatibility for Windows XP Pack 2 or 3, to run it as administrator but no...  :(

So I'm asking if somebody has a solution or knows where I did sh*t. Only one point maybe make me doubt, is in the readme of the bugfix file, where it is said to put the new file in C:\Program Files\SC4PIM\ directory but me I don't have any Directory file in my SC4PIM file. So I put it directly in the SC4PIM file and it asked me if I wanted to replace the other one, to what I said yes of course. But no effect when I try to start it...
Thank you guys for still trying to help disabled people like me after years ...
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: LReyomeXX on December 11, 2015, 09:18:36 PM
My issue is with ImportError: MemoryLoadLibrary failed loading tools3D.pyd on Terraformer

Also get an error when trying to open the library.zip file, something about invalid

Windows 10 64-Bit, tried running in XP SP3 compatibility mode and Windows 7 compatibility mode with admin privileges both times
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: vortext on December 12, 2015, 04:50:44 AM
It's normal the library zip cannot be opened. Instead multiarray.pyd should be placed in the TF installation folder. Also make sure the proper dll files are in there as well, especially msvcp71.dll. Finally I'm on win8.1 and run it in XP SP2 compatibility mode, could give that a go. 
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: dannyd1993 on September 11, 2018, 07:30:23 PM
Quote from: docj101 on May 10, 2013, 10:54:27 PM
I am running Win8 64bit.  I was getting this error when starting PIMx:

QuoteTraceback (most recent call last):
  File "SC4PIM.py", line 1, in ?
  File "SC4PIMApp.pyo", line 96, in ?
  File "wx\__init__.pyo", line 45, in ?
  File "wx\_core.pyo", line 4, in ?
  File "wx\_core_.pyo", line 12, in ?
  File "wx\_core_.pyo", line 10, in __load
ImportError: DLL load failed: The specified module could not be found.

I tried putting the new multiarray.pyd file into my SC4PIM folder and it didn't change my results. 

I changed my compatibility settings to: run in compatibility mode for 'WinXP (service pack 2)' and 'run program as administrator', now the program works perfectly again. 

Just thought I would mention this in case somebody else forgot about compatibility settings like I had momentarily.

I am getting the same message here. I am running windows 10. Tried running it in compatibility mode for Windows 7, and XP sp2. Same message. I tried the patch mentioned at the beginning of this thread and that didn't work either. Reinstalled and only added the New Properties XML. Any help would be greatly appreciated.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: twalsh102 on September 11, 2018, 08:07:11 PM
Make sure the .dlls mentioned in the very first post of the PIMX Official support thread (http://sc4devotion.com/forums/index.php?topic=9279.0) are downloaded and placed in the PIM-X installation folder. 

I just transferred all my stuff from a Win 7 computer to a new Win 10 computer, and initially had the same problem after reinstalling PIM-X.  Following the instructions for the .dlls fixed the problem.
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: dannyd1993 on September 11, 2018, 09:46:56 PM
That did the trick! Thanks!
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: FoxtrotF on April 18, 2023, 11:01:57 AM
Hello, I'm facing same error. Also with SC4DataPacker. Any ideas what can try next? I did every possible manipulations with mentioned dlls, their versions x64, x86, Reinstalled all  the C++ Redistributionals. But app dint't launch. no error, or logs, nothing. I check Event Viewer it stated, that wxWidgets "wxbase28uh_vc.dll" is a failing module, I downloaded and replaced this dll. And after that, application started to throw eror and log file with:

Traceback (most recent call last):
  File "SC4PIM.py", line 1, in ?
  File "SC4PIMApp.pyo", line 96, in ?
  File "wx\__init__.pyo", line 45, in ?
  File "wx\_core.pyo", line 4, in ?
  File "wx\_core_.pyo", line 12, in ?
  File "wx\_core_.pyo", line 10, in __load
ImportError: DLL load failed: The specified module could not be found.

Any ideas what libraries I need to install, may be wxWidgets?
Title: Re: PIM-X Bug on Win7 SP1 - Fixed!
Post by: mgb204 on April 19, 2023, 02:25:25 AM
Literally the very last problem/fix was identical to yours. So I suspect perhaps you don't have the right file, use the one in the link and you should be fine. Review the posts just above yours all the info is there.