http://GameProgrammer.Com

Programming

GP Mailing List
     Thread Index
     Date Index

ATXGPSIG List
     Thread Index
     Date Index

Google
>

Home

Wise2Food



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

pointer versus array?



============================================================
Searching for "a clean, well-organized place" for email? My
Topica was designed with people like you in mind. Stop by
and see what you think at
http://click.topica.com/caaabBzbUrGczbU68iFa/register
============================================================

hi guys,

i have a little problem:

class person
{
	private:
	char name[ 50 ];

	public:
	void setName( char string[] )
	{ name = string; }
	.
	.
	.
};

gives me the error;
error C2440: '=' : cannot convert from 'char []' to 'char [50]'

i need the private variable to be an array, what kind of argument do i
need on setName() so that this will work.

i know it's probably a simple pointer issue, and there are many pointer
gurus on this list, and i thank you for any help

russ


-- 
www.russelldsmith.freeservers.com

==^================================================================
EASY UNSUBSCRIBE click here: http://topica.com/u/?bUrGcz.bU68iF
Or send an email To: gameprogrammer-unsubscribe@topica.com
This email was sent to: list@pendleton.com

T O P I C A  -- Learn More. Surf Less.
Newsletters, Tips and Discussions on Topics You Choose.
http://www.topica.com/partner/tag01
==^================================================================