Archicad C++ API
About Archicad add-on development using the C++ API.
SOLVED!

Is there the limit of character length in .grc file?

Anonymous
Not applicable
Hi,
When I edit the .grc file,e.g I compile the code. the error occur, But I set the less characters, these is not error. I want to know whether there is the limit of chinese characters in grc file.

thanks.
1 ACCEPTED SOLUTION

Accepted Solutions
Solution
Tibor Lorantfy
Graphisoft Alumni
Graphisoft Alumni
We were not able to reproduce your issue. It built successfully for us without any errors.
Please make sure that your GRC file's encoding is "UTF-8 with BOM".

View solution in original post

11 REPLIES 11
akomporday
Graphisoft
Graphisoft
Hi DevJeer,
Could you please upload the file or copy-paste the relevant part here, so I can try to reproduce the error?
Anonymous
Not applicable
Hi akomporday ,
The relevant code :
'GDLG'  ID_DIALOG_FILE_RENAME  Modal | noGrow    100   100  720  734  "文件命名配置" {
/* [  1] */ Button				  554   694   78   30	LargePlain  "保存"
/* [  2] */ Button				  642   694   78   30	LargePlain  "取消"
/* [  3] */ Button				  466   694   78   30	LargePlain  "应用"
/* [  4] */ TextEdit				15   42   400   30	LargePlain  100                   
/* [  5] */ CheckBox				15   99  200   30	LargePlain	"启用字符分隔符"
/* [  6] */ PopupControl		    15    163  150   30	 80  3						
/* [  7] */ PopupControl		    185    163  150   30	 80  3						
/* [  8] */ LeftText			  15   20   84   20	LargePlain  "总文件平面名称"
/* [  9] */ LeftText			  15   141   60   20	LargePlain  "字符分隔符"                  
/* [  10] */ LeftText			  185   141   72   20	LargePlain  "建筑编号排序"
}
Thanks.
Solution
Tibor Lorantfy
Graphisoft Alumni
Graphisoft Alumni
We were not able to reproduce your issue. It built successfully for us without any errors.
Please make sure that your GRC file's encoding is "UTF-8 with BOM".
Anonymous
Not applicable
Tibor wrote:
We were not able to reproduce your issue. It built successfully for us without any errors.
Please make sure that your GRC file's encoding is "UTF-8 with BOM".
thanks
Anonymous
Not applicable
Tibor wrote:
We were not able to reproduce your issue. It built successfully for us without any errors.
Please make sure that your GRC file's encoding is "UTF-8 with BOM".
Thanks. My grc file's encoding is "UTF-8 with BOM". But Often "illegal character" error occurs when there are many chinese characters in my grc file.
The error occurs in ***.grc.rc2.i file. How can I solve it ?
leilei
Enthusiast
When you make a compilation error, put a space after the Chinese character.I compiled it in this way.
This problem occurs in Simple Chinese version of vs studio.
Anonymous
Not applicable
leilei wrote:
When you make a compilation error, put a space after the Chinese character.I compiled it in this way.
This problem occurs in Simple Chinese version of vs studio.
Thank you very much.
According to your method, this problem is solved.

Besides, I use Simple Chinese version of vs 2015.But I install the English Language pack ,the problem also occurs. I think the problem may be not caused by the vs language version ?
Akos Somorjai
Graphisoft
Graphisoft
Hi,

How do you you call ResConv in the custom build step of your .grc file?

Thanks, Akos
Anonymous
Not applicable
Akos wrote:
Hi,

How do you you call ResConv in the custom build step of your .grc file?

Thanks, Akos
My method that call ResConv is:

cl /nologo /X /EP /P /I "..\..\Support\Inc" /I "..\..\Support\Modules\DGLib" /I ".\Src" /FI"..\..\Support\Inc\utf8header.h" /DDEBUG /DWINDOWS /Fi"$(OutDir)\RO\$(ProjectName).grc.rc2.i" "RINT\$(ProjectName).grc"
"..\..\Support\Tools\Win\ResConv.exe" -m r -D WINDOWS -T W -q utf8 1252 -i "$(OutDir)\RO\$(ProjectName).grc.rc2.i" -D _DEBUG -o "$(OutDir)\RO\$(ProjectName).grc.rc2"