Can you fly an airplane at a 90° roll angle without losing altitude?
It depends. As always. If thrust is high enough, why not?
Knife edge flight is a regular part of aerobatic performances, and the fuselage is producing almost* all the needed lift. This requires

Enough speed,
A low ratio of aircraft mass to fuselage side area, and
Enough rudder deflection to trim the aircraft in a sufficiently high sidelip angle.

For horizontal flight your installed thrust must be sufficient to compensate for the high drag in this attitude. This should be no problem with powerful propeller aircraft if their fuel system keeps them supplied at this attitude. Jets must make sure that the sideslip angle can be tolerated by the intake.

The smoke from the exhaust indicates that this biplane flies horizontally. Yes, it is a large model airplane (not man-carrying, but almost big enough for that). But the laws of physics don't change with scale. For an example of a full-size aircraft doing a knife edge, see this video. Thanks go to @romkyns for pointing this out to me!
Note the rudder deflection to keep it at this angle of sideslip. Direction is controlled with the elevator. At this rate of sideslip the propeller thrust contributes to overall lift as well, however, the vertical adds a substantial downforce in order to trim the aircraft and the fuselage has to supply the remaining lift.
* Almost means that the propeller will carry some of the weight, but the large downforce on the vertical needs to be compensated, too. In sum, the lift contributed by the fuselage is very close to the weight of the plane.