Click here to Skip to main content
15,887,371 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: CString count Pin
Michael Schubert7-Sep-09 23:34
Michael Schubert7-Sep-09 23:34 
GeneralRe: CString count Pin
rdop7-Sep-09 23:37
rdop7-Sep-09 23:37 
JokeRe: CString count Pin
Cedric Moonen7-Sep-09 23:38
Cedric Moonen7-Sep-09 23:38 
GeneralRe: CString count Pin
Michael Schubert7-Sep-09 23:43
Michael Schubert7-Sep-09 23:43 
AnswerRe: CString count Pin
Cedric Moonen7-Sep-09 23:37
Cedric Moonen7-Sep-09 23:37 
JokeRe: CString count Pin
David Crow8-Sep-09 3:14
David Crow8-Sep-09 3:14 
AnswerRe: CString count Pin
Richard MacCutchan7-Sep-09 23:39
mveRichard MacCutchan7-Sep-09 23:39 
QuestionRe: CString count Pin
CPallini7-Sep-09 23:44
mveCPallini7-Sep-09 23:44 
What about
CString name = "agsdfgggggg";
int l = name.GetLength();

int count=0;

while (l-- > 0)
{
  if ( name[l] != 'g') break;
  count++;
}

if ( count > 0 )
{
  name = name.Left(name.GetLength() - count);
}

?

[added]
Sorry for the poor answer, I didn't realize that correct one is LIQUID NITROGEN.
[/added]
Smile | :)

If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.

This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke

[My articles]

AnswerRe: CString count Pin
rdop7-Sep-09 23:53
rdop7-Sep-09 23:53 
AnswerRe: CString count Pin
«_Superman_»8-Sep-09 0:26
professional«_Superman_»8-Sep-09 0:26 
QuestionHow to compare two HKEY handles Pin
i.dachev7-Sep-09 21:30
i.dachev7-Sep-09 21:30 
AnswerRe: How to compare two HKEY handles Pin
Christian Graus7-Sep-09 21:38
protectorChristian Graus7-Sep-09 21:38 
GeneralRe: How to compare two HKEY handles Pin
i.dachev7-Sep-09 21:56
i.dachev7-Sep-09 21:56 
GeneralRe: How to compare two HKEY handles Pin
Garth J Lancaster7-Sep-09 22:03
professionalGarth J Lancaster7-Sep-09 22:03 
GeneralRe: How to compare two HKEY handles Pin
i.dachev7-Sep-09 22:31
i.dachev7-Sep-09 22:31 
AnswerRe: How to compare two HKEY handles Pin
kilt10-Sep-09 6:40
kilt10-Sep-09 6:40 
QuestionHow do test dll which is created in C Pin
mohant$.net7-Sep-09 20:27
mohant$.net7-Sep-09 20:27 
AnswerRe: How do test dll which is created in C Pin
Cedric Moonen7-Sep-09 20:38
Cedric Moonen7-Sep-09 20:38 
AnswerRe: How do test dll which is created in C [modified] Pin
CPallini7-Sep-09 21:23
mveCPallini7-Sep-09 21:23 
AnswerRe: How do test dll which is created in C Pin
Selvam R8-Sep-09 0:14
professionalSelvam R8-Sep-09 0:14 
GeneralRe: How do test dll which is created in C Pin
mohant$.net8-Sep-09 0:17
mohant$.net8-Sep-09 0:17 
GeneralRe: How do test dll which is created in C Pin
Selvam R8-Sep-09 0:23
professionalSelvam R8-Sep-09 0:23 
QuestionDouble getlength Pin
Davitor7-Sep-09 20:03
Davitor7-Sep-09 20:03 
AnswerRe: Double getlength Pin
Cedric Moonen7-Sep-09 20:24
Cedric Moonen7-Sep-09 20:24 
GeneralRe: Double getlength Pin
Davitor7-Sep-09 20:37
Davitor7-Sep-09 20:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.