Pain in top of right top of pelvis when coughing?

Muscle/hernia. The most likely culprits would be a pulled muscle or an abdominal hernia. Both of these conditions can be easily diagnosed at your doctors office.