Number of Arguments / MySQL
#1

Having an issue when compiling, it's giving me two warnings about number of arguments:

Warnings:
Код:
1.2.pwn(13645) : warning 202: number of arguments does not match definition
1.2.pwn(13647) : warning 202: number of arguments does not match definition
Lines:
Код:
PlayerData[extraid][pContractReason] = cache_get_field_content(0, "ContractReason");
PlayerData[extraid][pContractedBy] = cache_get_field_content(0, "ContractedBy");
Reply
#2

How does this pContractReason look like in the player enum structure? Does it have a size with it?

Код:
enum pInfo

       pContractReason[60]

yadayadayadayada
Reply
#3

This is how you use cache_Get_field_content:

pawn Код:
new string[size];
cache_get_field_content(row_index, "column_name", string);
If you want to get an integer or a flow, you cache_get_field_content_int or cache_get_field_content_float:
pawn Код:
new int = cache_get_field_content_int(row_index, "column_name");
new Float:value = cache_get_field_content_Float(row_index, "column_name");
Reply
#4


Inside my enum
Reply
#5

Then use
pawn Код:
cache_get_field_content(0, "ContractReason", PlayerData[extraid][pContractReason], connection_handle, 126);
cache_get_field_content(0, "ContractedBy", PlayerData[extraid][pContractedBy], connection_handle, 126);
Reply
#6

Quote:
Originally Posted by dusk
Посмотреть сообщение
Then use
pawn Код:
cache_get_field_content(0, "ContractReason", PlayerData[extraid][pContractReason], connection_handle, 126);
cache_get_field_content(0, "ContractedBy", PlayerData[extraid][pContractedBy], connection_handle, 126);
Thanks, it's worked.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)