i guess in ur example that the person who said "ya rab" asks God for something good for the person he/she is speaking to, "ya rab" means "o God" or "please God", it's said when:
1- someone mentions God, in this case it means "o God"
2- someone asks God for something he/she wants
3- someone asks God that something someone else wants happens to him/her, for example person A wants a house so person B asks God that person A have this house, in this case if person B wants a house too person A would reply and say "we enta kaman" which means "u too" which is short of "i wish u have a house too"
so in ur example the 2nd person replies and says "wa enta kaman" which means "u too" which refers to that the 2nd person asks God too that the 1st person have this good thing too
as for the 3rd person who replies and says "wa enta tany" i don't know what he/she means, it literally means "and u again", i think there's no 3rd person probably the 1st person replies and says "wa enta tany" which means "and u again" for emphasis