I am rather new to AddOn development. I would like to write Trading House listing data to SavedVariables so that I can process these listed items outside ESO in order to keep track of what I listed for sale.
I am a member of two Guilds: one is my 'regular' guild that has no trader, and the other one is the Trading guild that I use for selling things. I am using this code:
Lua Code:
for j = 1, GetNumGuilds() do
local guildId = GetGuildId(j)
if (SelectTradingHouseGuildId(guildId)) then
local currentListingCount, maxListingCount = GetTradingHouseListingCounts()
if(currentListingCount > 0) then
for i = 1, currentListingCount do
local _,itemName,displayQuality,stackCount,_,timeRemaining,salePrice = GetTradingHouseListingItemInfo(i)
local link = GetTradingHouseListingItemLink(i,j)
local linkItemId = GetItemLinkItemId(link)
table.insert(mytable,string.format("%s;%s;%s;%s;%s",guildId,linkItemId,itemName,salePrice,timeRemaining))
end
end
end
end
This returns a table that contains twice the number of items, exactly the same for each guild although one of the guilds has no sellable items. What am I missing here?
The above code only works when I visit the bank, and open the listing from the guild trader.
Is there a way to access the listing data in the bank without actually visiting the bank?
Thank you in advance