this is how mine is set up
change the func80 81 82 to what you have in your item db FLD_ANICOUNT , also make sure the item is stmode 31
::-Qfun part
[@StdModeFunc80]
#IF
checkgold 490000001
#SAY
You cannot Exchange goldbar into money.\
your bankbalance would exceed its limit.\ \
<Cancel/@exit>
#ACT
GIVE GoldBar 1
BREAK
#ELSEACT
give gold 1000000
SENDMSG 6 "GoldBar was Exchanged into money."
[@StdModeFunc81]
#IF
checkgold 450000001
#SAY
You cannot Exchange goldbarbundle into money.\
your bankbalance would exceed its limit.\ \
<Cancel/@exit>
#ACT
GIVE GoldBarBundle 1
BREAK
#ELSEACT
give gold 5000000
SENDMSG 6 "GoldBarBundle was Exchanged into money."
[@StdModeFunc82]
#IF
checkgold 400000001
#SAY
You cannot Exchange goldbarchest into money.\
your bankbalance would exceed its limit.\ \
<Cancel/@exit>
#ACT
GIVE GoldChest 1
BREAK
#ELSEACT
give gold 10000000
SENDMSG 6 "GoldChest was Exchanged into money."