Click here to Skip to main content
15,031,495 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionPlease help regarding the following error Pin
hits0719-Sep-07 18:57
Memberhits0719-Sep-07 18:57 
AnswerRe: Please help regarding the following error Pin
nbugalia19-Sep-07 19:27
Membernbugalia19-Sep-07 19:27 
GeneralRe: Please help regarding the following error Pin
hits0719-Sep-07 19:41
Memberhits0719-Sep-07 19:41 
GeneralRe: Please help regarding the following error Pin
nbugalia19-Sep-07 20:06
Membernbugalia19-Sep-07 20:06 
GeneralRe: Please help regarding the following error Pin
David Crow20-Sep-07 2:49
MemberDavid Crow20-Sep-07 2:49 
Questionadd files and foldder selection box on button click Pin
Dhiraj kumar Saini19-Sep-07 18:44
MemberDhiraj kumar Saini19-Sep-07 18:44 
AnswerRe: add files and foldder selection box on button click Pin
nbugalia19-Sep-07 19:23
Membernbugalia19-Sep-07 19:23 
QuestionHow to avoid flickering in CListCtrl Pin
shir_k19-Sep-07 18:11
Membershir_k19-Sep-07 18:11 
Hi,

I have list control whose property is set to
"List1",IDC_CmdResp,"SysListView32",LVS_REPORT |
WS_BORDER | WS_TABSTOP,293,37,146,214,
WS_EX_DLGMODALFRAME | WS_EX_CLIENTEDGE | WS_EX_RIGHT |
WS_EX_STATICEDGE

Am displaying the data read from the serial port in the list control but there is lot of filckering.Below is the code to display the data in list control.Is there any thing am missing in the code.Why there is flickering?More flickering starts when i start deleting the data.If i don't delete i get assert error that maybe due to memory overflow of the list control.Plz help me out.


void CNgpptDialog::ReadSerialData(CString sIn)
{

CString pressure_data;

ptrCmdResp->SetRedraw(false);
pressure_data=sIn;
int counter = ptrCmdResp->GetItemCount();
ptrCmdResp->InsertItem(counter, "");// to insert a row
ptrCmdResp->SetItemText(counter, 0, pressure_data);// column0
ptrCmdResp->EnsureVisible(counter, FALSE); // Scrolls downwords.

if(counter > 150)// I start deleting first data when the number of items in the list control is > 150
{
ptrCmdResp->DeleteItem(0);
}

ptrCmdResp->SetRedraw(true);
int nIndex = ptrCmdResp->GetItemCount();
ptrCmdResp->RedrawItems(nIndex,nIndex);
}

}


Thanks in advance
AnswerRe: How to avoid flickering in CListCtrl Pin
Nelek19-Sep-07 20:08
protectorNelek19-Sep-07 20:08 
GeneralRe: How to avoid flickering in CListCtrl Pin
shir_k20-Sep-07 20:36
Membershir_k20-Sep-07 20:36 
GeneralRe: How to avoid flickering in CListCtrl Pin
Nelek21-Sep-07 1:44
protectorNelek21-Sep-07 1:44 
AnswerRe: How to avoid flickering in CListCtrl Pin
David Crow20-Sep-07 2:45
MemberDavid Crow20-Sep-07 2:45 
GeneralRe: How to avoid flickering in CListCtrl Pin
shir_k20-Sep-07 20:24
Membershir_k20-Sep-07 20:24 
QuestionRe: How to avoid flickering in CListCtrl Pin
David Crow21-Sep-07 2:40
MemberDavid Crow21-Sep-07 2:40 
QuestionHelp me convert Pin
monsieur_jj19-Sep-07 16:15
Membermonsieur_jj19-Sep-07 16:15 
AnswerRe: Help me convert Pin
monsieur_jj19-Sep-07 17:07
Membermonsieur_jj19-Sep-07 17:07 
QuestionMemory Corruption [modified] Pin
devvvy19-Sep-07 15:59
Memberdevvvy19-Sep-07 15:59 
AnswerRe: Memory Corruption Pin
Roger Broomfield19-Sep-07 18:07
MemberRoger Broomfield19-Sep-07 18:07 
GeneralRe: Memory Corruption Pin
devvvy19-Sep-07 18:10
Memberdevvvy19-Sep-07 18:10 
QuestionHow to Monitor an application which required kill and regenerate if hang Pin
littlecheer19-Sep-07 15:18
Memberlittlecheer19-Sep-07 15:18 
AnswerRe: Monitor an application - kill and regenerate if hang Pin
Nathan Holt at EMOM19-Sep-07 15:42
MemberNathan Holt at EMOM19-Sep-07 15:42 
GeneralRe: Monitor an application - kill and regenerate if hang Pin
littlecheer19-Sep-07 15:55
Memberlittlecheer19-Sep-07 15:55 
GeneralRe: Monitor an application - kill and regenerate if hang Pin
devvvy19-Sep-07 18:49
Memberdevvvy19-Sep-07 18:49 
GeneralRe: Monitor an application - kill and regenerate if hang Pin
ThatsAlok19-Sep-07 20:35
MemberThatsAlok19-Sep-07 20:35 
GeneralRe: Monitor an application - kill and regenerate if hang Pin
devvvy19-Sep-07 20:43
Memberdevvvy19-Sep-07 20:43 

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.