-
January 17th, 2011, 11:03 PM
#1
Simple Pointer issue
Hello,
New to c++ and windows programming.
int Current_Amount_Of_Groups = 1;
wchar_t *Group_Name = "Name";
a) wchar_t buf[30];
b) wchar_t *buf= new wchar_t[30];
swprintf_s( buf, 30, L"%i", Current_Amount_Of_Groups );
wcsncat_s( buf, Group_Name),10);
When I use a) the wsprintf_s and wcsncat_s functions work fine, but when I use b) the swprintf_s works and wcsncat_s does not.
My issue:
I thought by using a) and inputting buf to wcsncat_s was inputting a pointer to an array. So why am I having an issue using b) by inputting a pointer to an array? see my problem?
P.S compiler says: No Instance of overloaded function "wcsncat_s" matches the argument list.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|