MrDante Posted July 23, 2016 Share Posted July 23, 2016 Hello Guys, I have Problem. Sorry my bad english I've never used xml anything, I would get all elements name and put in a Gridlist, but by adding to it there are no mistakes, only not appear on the grid If you can help me I will be grateful Client local Grid2 = guiCreateGridList(botX+sizeX+443, botX2+sizeX2+275, 188, 190, false) function vtrs.abrirpmesp (_, estado) if painelpmesp[1] == true and painelpmesp[2] == false then if estado == "down" then if isCursorOnElement(botX+sizeX+210, botX2+sizeX2+289, 210, 32) then setTimer( function () Gridlist:SetVisible(true) end, 2000, 1) local xml = xmlLoadFile("Arquivos/Xml/Veiculos.xml") for _, group in ipairs (xmlNodeGetChildren(xml)) do local id = xmlNodeGetAttribute(group, "id") local veh = xmlNodeGetAttribute(group, "name") guiGridListSetItemText(Grid2, guiGridListGetSelectedItem(Grid2), 1, veh, false, false) end painelpmesp[2] = true painelpmesp[3] = false painelpmesp[4] = false tick = getTickCount() addEventHandler("onClientRender", root, painelcdvpmesp2) removeEventHandler("onClientRender", root, painelcdvpmesp3) removeEventHandler("onClientRender", root, painelcdvpmesp5) playSound("Arquivos/Sons/click.mp3") end end end end addEventHandler("onClientClick", root, vtrs.abrirpmesp) Xml "490" name = "ROX GOSTOSO" /> "490" name = "PRF GddsaO" /> "490" name = "RsaasaasddaTOSO" /> Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now