brennbar67
Member level 3
Array problem....
Dear all,
Does anyone know how to stor character by character into a array?
That mean, in beginning the contain inside array is empty, when a user keying a number/alphabet, i need to stor the number/alphabet into the array.
Here is my program,but when i complie,it give me some warning...like this <assign far pointer to near pointer,bank value ignored>, why?
unsigned char *phonebook[20];
unsigned int phone_size=0;
void main()
{....
....
phonebook[phone_size]= "9"; //assume user key in number 9
phone_size++;
....
....
display();
}
void display(void)
{ int i;
for(i=0;i<10;i++)
{
phonebook;
}
}
Does anyone can point out my problem,pls??thanks !!
Dear all,
Does anyone know how to stor character by character into a array?
That mean, in beginning the contain inside array is empty, when a user keying a number/alphabet, i need to stor the number/alphabet into the array.
Here is my program,but when i complie,it give me some warning...like this <assign far pointer to near pointer,bank value ignored>, why?
unsigned char *phonebook[20];
unsigned int phone_size=0;
void main()
{....
....
phonebook[phone_size]= "9"; //assume user key in number 9
phone_size++;
....
....
display();
}
void display(void)
{ int i;
for(i=0;i<10;i++)
{
phonebook;
}
}
Does anyone can point out my problem,pls??thanks !!