Try to build two arrays, one for panel pointers, another for the names.
Store each panel pointers and regarding the names paralell.
Like this:
PANEL* cardpanels[500];
STRING* panelnames[500];
Store the pointers and the names when they occurs.
For example:
panelnames[5]="5thcard";
cardpanels[5]=pan_create(NULL,2);
cardpanels[5].bmap = bmap_create("nicecard.tga");
cardpanels[5].pos_x=400;
cardpanels[5].pos_y=200;
...
set other panel attributes
You can organize this activity into a loop if you can load the datas from file or create somehow the datas and the names.
In this case you have to save everything in a file, open that and read all lines. Just for fun:
for(index=0; index<500; index++) {
file_str_read(fhnd_n,mystring);
posx=file_var_read();
posy=file_var_read();
panelnames[index]=mystring;
cardpanels[index]=pan_create(NULL,2);
cardpanels[index].bmap = bmap_create(mystring);
cardpanels[index].pos_x=posx;
cardpanels[index].pos_y=posx;
}