RobotStudio event

How use Trans Function correctly.....

Hi everyone i have a question and i hope someone can help me. My question is about Trans Function i have a project with dispense  equipment so i need dispense in several position in one pallet is a Matrix 4 columns and 7 rows, so i do one routine where i have the movements of the countour of the piece and i have one Function to move of each position in the matrix using Trans.oframe but when i change of position i have drifts in the movemets of the robot so i remember that you can use trans in one robtarget variable and only use trans in this point and then you can call the routine of the countur but i dont remembre how do it sonplease someone can help me about this or if someone have a better idea how can move in the matrix without drift in the robot please ?????