Split surface by curves

Hi All
I am looking to split the surface created from top of floor by wall location line and create closed curve.
Please find attached image

Thank you very much. its work as expected. i still not understood the concept of split surface with Polysurface.ByjoinedSurface.