cant update editbox after changing font

hi guys
im making an mfc appilication to do some textediting
when i wanna change my font,i press a button and choose from a list-box one font,then i use control to change font,but first time i choose font,it wont work,i should choose another time to apply it,i think i need to update it first time i use
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
void CmfctexteditortextboxDlg::OnBnClickedButton4()
{
	okbut.ShowWindow(TRUE);
	CString s1=NULL;
	CString s2=NULL;
	active->ShowWindow(FALSE);
	listcontrol.ShowWindow(TRUE);
	int row = listcontrol.GetSelectionMark();
	s1=listcontrol.GetItemText(row,0);
	s2=listcontrol.GetItemText(row,1);
//i cut some useless code for u guys
		active->SetFont(//my font);
//in this funtion my edit box that was hidden,i make it visible again
void CmfctexteditortextboxDlg::OnBnClickedButton6()
{
	okbut.ShowWindow(FALSE);
	listcontrol.ShowWindow(FALSE);
	active->ShowWindow(TRUE);
}



}


thanks
Topic archived. No new replies allowed.