So are you ready for the real kicker?
It's more often than not, cheaper to demolish office blocks and build fresh residential than it is to convert office blocks to residential. This is because utilities like clean water, grey water, and black water have been built to a commercial office demand specification that residential exceeds.
The rest of it depends on the specifics of the building like fire escapes, width of stairways, number of elevators, the electricity runs, networking, etc.
Even if it can be done to meet legal requirements there are other factors that would make the price for these converted apartments crater meaning they would be sold with little profit and therefore no developer would take on the job.
For example: Air conditioning has to be completely redone because whole floors will be connected in series so if one flat doesn't want to pay for AC usage and disconnects then the whole floor of flats doesn't get AC.
Another one is having windows that you can't open. No sane person would buy an apartment in a city with no openable windows. And windows are often designed in parallel with the cladding and external fascia.
In short, you're better off ripping the whole building back to the steel frame and concrete pads, adding extra capacity for utilities, then starting the exterior and interior from scratch. And at that point it'd be quicker to demolish the original building entirely and build something new. Remember, the longer a project takes, the more likely it will be delayed. And delays cost more money.
It's not impossible, but the stars have to align to find a building where a retrofit is both possible and economically profitable enough.