It seems that this is an error caused by Visual Basic 6 application. Due to this, it's advised to update the VB6 program and your Windows with the latest versions available. Also, to be noticed that the Sims 2 NPC Replacer isn't an official application, but a fan made one. This can also lead to compatibilities error. If you can't fix your error, try contacting the developer on the official website.