can any one help me for how to write script for this test case
""Do not fill in all the Mandatory Data. Reiterate in a way such that all combinations of mandatory field are left blank. Press "Save" button."
Result is "User should be prompted with appropriate Error Message"
so my doubt is how to trap the error message and how to store it "
What I would do - is open this error message you need to trap, and try to recognize it's unique name and objects in it with Inspector. Once it's done - you can always get all info about existence/ non-existence of this message with SQAGet... commands. If you need to check message window existence, there is VP for Window Existence.
I have a similar test for a view with multiple required fields.
First I determined which fields were mandatory.
Next I checked what warning or error message opened when each individual mandatory field was left blank. You can do this by filling all but one mandatory field and checking them one by one. This is also how you would set up your automated script.
Once you know what warning messages are re-used you can plan your test script out. If the warning messages are generic and reused you can re-use your VP or click event once recorded. If the warning messages are unique you will have to record a VP or click event for each warning message.
DC Interact Commerce Corporation