The demo version of Mach3 allows 500 lines (give or take a couple) of code plus there are a few other limitations but nothing serious (not sure about 4th axis here). As long as a GCode program is written carefully 500 lines can be a lot of program.
You really need the full cable but step and direction for 3 axis plus limit switches and PU/PD (with common ground) could amount to only 11 wires so it may be possible, but hey, second user old printer extension cables cost peanuts.
Tweakie.