find some question in using Static Control | developer.brewmp.com find some question in using Static Control | developer.brewmp.com

Developer

find some question in using Static Control

Forums:

In programming, i find the function :

boolean ISTATIC_SetText
(
IStatic * pIStatic,
AECHAR * pTitle,
AECHAR * pText,
AEEFont fntTitle,
AEEFont fntText
)
can't work properly.

my code is as this:

void notebook_ViewText(notebook* pMe)
{
IDialog *pIDlg = NULL;
IStatic *pIStatic = NULL;
AECHAR hi[3] = { L'h', L'i', L'\0'};

ISHELL_CreateDialog(pMe->pIShell, NOTEBOOK_RES_FILE,IDD_NOTEBOOK_VIEW, NULL);
pIDlg = ISHELL_GetActiveDialog(pMe->pIShell);

pIStatic = (IStatic *)IDIALOG_GetControl(pIDlg, IDC_STATIC_7004);

ISTATIC_SetText(pIStatic, hi, hi, AEE_FONT_NORMAL, AEE_FONT_NORMAL);

ISTATIC_Redraw(pIStatic);

when i use the ISTATIC_SetText() and when i set the pointer of pText, my program cracked, when i don't set the parameter and only set the pointer of pTitle,
my program runs ok

thanks for your help