My daughter's dog{staff} used to do this when i went to visit, which was most day's, but when she visited me the dog did'nt piss, what i done was, when i first went into the house i would ignore the dog{as chalkwarren said} then when i sat down, the dog would come over to me and i would stroke her then, since i started this the dog has not done it, so i am gonna carry on that way as it work's, it is worth you trying it, nothing to lose, good luck.