UseContainerItem - WoWInterface
Thread Tools Display Modes
10-23-05, 04:50 AM   #1
A Defias Bandit
Join Date: Jan 2005
Posts: 3


I've a problem that gives me a lot of headache.

I've Heavy Runecloth Bandages in Backpack Slot 1.

If I create this macro:

/script Print(GetContainerItemLink(0, 1));
/script UseContainerItem(0,1);

and execute it I get the name of the bandage in the chat and the bandage is used.

now, if I create an addon with this function

function shark_test()
Print(GetContainerItemLink(0, 1));

and execute it by calling /script shark_test()

I get the name of the bandage into the chat, but it is NOT used. I get no error message.

what's going on?
  Reply With Quote
10-23-05, 04:57 AM   #2
A Fallenroot Satyr
Join Date: Jan 2005
Posts: 23
I guess you tried /script shark_test() on the commandline instead of a hotbutton? UseContainerItem may need a hardware event like CastSpellByName etc ... try to put /script shark_test() in a macro and test it as hotbutton.
  Reply With Quote
10-23-05, 05:38 AM   #3
A Defias Bandit
Join Date: Jan 2005
Posts: 3
You are right, thanks a lot!
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » UseContainerItem

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off