Hello. Yes, the frames are the same. I THINK you might have to use the 9mm ejector rather than the one that comes with the forty version as the latter is wider and won't work with the 9mm slide as it has a notch that is more narrow for the 9mm ejector. This may have changed as I've not compared the two in several years.
Best.
Best.