I don’t have much experience with Assemblies and Parts but I would assume the Part Element is not the same as the Instance Element. I’m guessing you might have to get the Instance from the Part and query the CS of the Instance. Unless you’re actually looking for the orientation of the Part compared to the Assembly… then it seems more complicated.
I don’t believe Walls have a Transform property. You probably won’t be able to get a local CS from a line-based system family in this way. I’d recommend determining the orientation “manually” via the location curve.