Hi Maj,
I think other forum members have answered your question. Following is a rule that can be applied in deciding the form of a pronoun--my or me.
In a formal writing, if a pronoun precedes a gerund, use the possessive form of the pronoun--Your/our/its/their/my...etc. For example,
(1) I...