2013-05-29 63 views
0

幫忙請Hunspell問題,不能使這個東西效果很好。 這是我的代碼,它返回bool值TRUE而不是字的建議。Hunspell返回布爾而不是文字

int main(array<System::String ^> ^args) 
{ 
    char *aff = "c:\\en_US.aff"; 
    char *dic = "c:\\en_US.dic"; 
       Hunspell *spellObj = new Hunspell(aff,dic); 
       const char *named = "hello"; 
       int result = spellObj->spell(named); 
       char ** wlst; 
       char ** wlst2; 
       int ns = spellObj->suggest(&wlst,named); 
       int abc = spellObj->analyze(&wlst2,named); 
       Console::WriteLine(ns); 
       for (int i = 0; i<ns; i++)     
       { 

Console::WriteLine(&wlst[i]); 
       } 
       spellObj->free_list(&wlst,ns); 
       delete spellObj; 
    Console::WriteLine(result); 
    getchar(); 
    return 0; 

我該如何使這個建議有效?

回答

0

必須使用std :: cout而不是Console :: WriteLine(facepalm)

相關問題