I was standing I gave this answer this answer . is this a correct way
Yes, it's grammatically correct, and you used the proper tense.
The lack of any contractions ("If you would've", "If you'd have...", etc.) makes it feel a bit stiff to me, but not using them isn't wrong, so don't worry.