开发者

How to get the length of a _bstr_t

I am copying a wstring to a _bstr_t using:

_bstr_t name;           
SysFreeString(name);   // Free previous string, if any.
name = SysAllocString(Member[k].Membername);

Now before I use "name" I want to check if it contains at least 5 characters. In other words, I want to check the length of it.

I didn't find a "countof" or "len" or something like that. Has anyone开发者_StackOverflow中文版 a idea?

Thanks, Lumpi


name.length()

http://msdn.microsoft.com/en-us/library/zthfhkd6%28v=VS.100%29.aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜