I actually managed to add on to this macro to make it swap out the item that is currently in the trade screen with another item that is in your inventory that has a very similar appearance. In addition, I've made the swap a bit faster, so if you're able to distract the person a little bit with text, and press one button, he might not even notice the swap. You would have to write something in the chat after he already puts in the gold amount.
#include <Misc.au3>
Opt('MouseCoordMode', 0)
Opt('PixelCoordMode', 0)
WinActivate('Diablo III')
While 1
If WinActive('Diablo III') Then
If _IsPressed('BB') Then
MouseClick("Left", 83, 278, 1, 0)
MouseClick("Left", 1233, 598, 1, 2)
MouseClick("Left", 814, 783, 1, 0)
MouseClick("Left", 84, 300, 1, 0)
MouseClick("Left", 182, 837, 1, 0)
While _IsPressed('BB')
Sleep(10)
WEnd
EndIf
EndIf
WEnd
This version works in 1280 x 1024 Windowed (fullscreen) mode, which is the highest resolution, but you are able to modify the mouse position by using AutoIt Window Info to accommodate your own resolution. If you're not able to get the AutoIt Window Info program to work, send me an e-mail. I can send you a quick script (not my own) that does the trick. Below is basically an image that shows the breakdown of the program above:

Place the original item that should be in the top right corner of your inventory into the trade screen, and click '=' when you're ready to swap it out with the item at the bottom left corner of your inventory. DO NOT MIX UP THE POSITIONS OF YOUR ITEMS. This script doesn't work both ways.
Theoretically, you should have a higher success rate than if you would use the original, but I haven't tested it yet. Of course, all credit goes to
I AM ALPHA for the original design.
P:S: The reason I picked these item locations in the inventory was because the program was for some reason not working well with similar mouse positions, though I'm not sure if that's the case since I'm a noob to programming.