WoW:API GetMerchantItemLink

From AddOn Studio
Revision as of 00:48, 13 January 2005 by WoWWiki>Fenaoin (Returns a link to the indexed item in the merchant's inventory)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
GetMerchantItemLink -Documentation by Fenaoin-


link = GetMerchantItemLink(index);

Returns a link to the indexed item in the merchant's inventory.


Arguments
(index)
index
Number - The index of the item in the merchant's inventory

Returns
link
link
String - returns a string that will show as a clickable link to the item

Example
local link = GetMerchantItemLink(4);
DEFAULT_CHAT_FRAME:AddMessage(link);
Result

The item from slot four's name will appear in the chat window in brackets. Clicking on it will open a small window with information about the item. An example of the string itself looks like this:

|cffffffff|Hitem:3771:0:0:0|h[Wild Hog Shank]|h|r

Template:WoW API