{"hash":"0x8F2EECC3","ns":"CFX","name":"START_FIND_EXTERNAL_KVP","slug":"START_FIND_EXTERNAL_KVP","official":true,"named":true,"luaName":"StartFindExternalKvp","game":"cfx","apiset":"client","returnType":"int","params":[{"name":"resourceName","type":"char*","description":"The resource to try finding the key/values for"},{"name":"prefix","type":"char*","description":"A prefix match"}],"returnsDescription":"A KVP find handle to use with [FIND_KVP](#\\_0xBD7BEBC5) and close with [END_FIND_KVP](#\\_0xB3210203)","summary":"Equivalent of START_FIND_KVP, but for another resource than the current one.","descriptions":[{"source":"cfx","format":"md","body":"Equivalent of [START_FIND_KVP](#\\_0xDD379006), but for another resource than the current one."}],"examples":[{"lang":"lua","code":"local kvpHandle = StartFindExternalKvp('drugs', 'mollis:')\n\nif kvpHandle ~= -1 then \n\tlocal key\n\t\n\trepeat\n\t\tkey = FindKvp(kvpHandle)\n\n\t\tif key then\n\t\t\tprint(('%s: %s'):format(key, GetResourceKvpString(key)))\n\t\tend\n\tuntil not key\n\n\tEndFindKvp(kvpHandle)\nelse\n\tprint('No KVPs found')\nend","source":"cfx"}],"aliases":[],"enums":[],"related":[],"sources":["cfx"],"doc":3,"url":"https://natives.borderlinerp.com/natives/CFX/START_FIND_EXTERNAL_KVP","markdownUrl":"https://natives.borderlinerp.com/natives/CFX/START_FIND_EXTERNAL_KVP.md","snippets":{"lua":"local retval = StartFindExternalKvp(resourceName, prefix)","luaInvoke":"local retval = Citizen.InvokeNative(0x8f2eecc3, resourceName, prefix, Citizen.ResultAsInteger())","js":"const retval = StartFindExternalKvp(resourceName, prefix);","jsInvoke":"const retval = Citizen.invokeNative('0x8f2eecc3', resourceName, prefix, Citizen.returnResultAnyway(), Citizen.resultAsInteger());","csharp":"int retval = Function.Call<int>((Hash)0x8f2eecc3, resourceName, prefix);","notes":[]}}