Solved

Tgroupbox caption

Posted on 2003-11-05
6
303 Views
Last Modified: 2010-04-05
I store the strings caption  of controlls in inifile...all controlls accept these caption except tgroupboxs.
I Write this code:-

procedure callARABIC();
begin
try
with form1 do
begin

langfile := TIniFile.Create(ExtractFilePath(ParamStr(0))+'ARBlang.ini');
//button
cmdok.Caption := langfile.ReadString('button','cmdok',cmdok.Caption );
cmdcul.Caption := langfile.ReadString('button','cmdcul',cmdcul.Caption );
cmdclear.Caption := langfile.ReadString('button','cmdclear',cmdclear.Caption );
//box
sheet1.Caption := langfile.ReadString('box','sheet1',sheet1.Caption );
sheet2.Caption := langfile.ReadString('box','sheet2',sheet2.Caption );
Caption := langfile.ReadString('box','form1',Caption );
typebox.Caption := langfile.ReadString('box','typebox',typebox.Caption );
sbox.Caption := langfile.ReadString('box','sbox',sbox.Caption );
resultbox.Caption := langfile.ReadString('box','resultbox',resultbox.Caption );
culbox.Caption := langfile.ReadString('box','culbox',culbox.Caption );
//radio
r220.Caption := langfile.ReadString('radio','r220',r220.Caption );
c220.Caption := langfile.ReadString('radio','c220',c220.Caption );
r380.Caption := langfile.ReadString('radio','r380',r380.Caption );
c380.Caption := langfile.ReadString('radio','c380',c380.Caption );
SAREA.Caption := langfile.ReadString('radio','SAREA',SAREA.Caption );
SCONNECTED.Caption := langfile.ReadString('radio','SCONNECTED',SCONNECTED.Caption );
v220.Caption := langfile.ReadString('radio','v220',v220.Caption );
v380.Caption := langfile.ReadString('radio','v380',v380.Caption );
//Label
Sf.Caption := langfile.ReadString('label','Sf',Sf.Caption );
Sc.Caption := langfile.ReadString('label','Sc',Sc.Caption );
Sc2.Caption := langfile.ReadString('label','Sc2',Sc2.Caption );
Scbamp.Caption := langfile.ReadString('label','Scbamp',Scbamp.Caption );
Scbkva.Caption := langfile.ReadString('label','Scbkva',Scbkva.Caption );
srconn.Caption := langfile.ReadString('label','srconn',srconn.Caption );
srcont.Caption := langfile.ReadString('label','srcont',srcont.Caption );
//menuform
File1.Caption := langfile.ReadString('menuform','File1',File1.Caption );
Engneering1.Caption := langfile.ReadString('menuform','Engneering1',Engneering1.Caption );
relationdept1.Caption := langfile.ReadString('menuform','relationdept1',relationdept1.Caption );
Exit1.Caption := langfile.ReadString('menuform','Exit1',Exit1.Caption );
Option1.Caption := langfile.ReadString('menuform','Option1',Option1.Caption );
skin.Caption := langfile.ReadString('menuform','skin',skin.Caption );
noskin.Caption := langfile.ReadString('menuform','noskin',noskin.Caption );
ENGLISH.Caption := langfile.ReadString('menuform','ENGLISH',ENGLISH.Caption );
ARABIC.Caption := langfile.ReadString('menuform','ARABIC',ARABIC.Caption );
Help.Caption := langfile.ReadString('menuform','Help',Help.Caption );
subhelp.Caption := langfile.ReadString('menuform','subhelp',subhelp.Caption );
ABOUT1.Caption := langfile.ReadString('menuform','ABOUT1',ABOUT1.Caption );

end; //end with
 finally
langfile.Free ;
end;
end;
0
Comment
Question by:sal1150
  • 3
  • 3
6 Comments
 
LVL 5

Expert Comment

by:snehanshu
ID: 9686082
sal1150,
  There doesn't seem any reason why that should happen.
  Can you post:
1) the names of the groupboxes in the above code (are those the ones under //box?)
2) the contents of your ini file. It could be a problem with the section-key combination.
...Snehanshu
0
 

Author Comment

by:sal1150
ID: 9692972
1) the names of the groupboxes in the above code are:-
                    typebox   -  sbox  -  resultbox   -  culbox
2) the contents of my ini file (arblang):-

[box]
sheet1=جداول احمال المشترك
sheet2=تحديد غرفة المحول
form1=ضوابط حساب احمال المشترك الجديدة والمعتمدة من الوزارة
typebox=انواع الجداول المقررة
sbox=خيارات البحث
resultbox=النتيجة
culbox=نتيجة الحساب

[button]
cmdok=موافق
cmdcul=حساب
cmdclear=مسح

[radio]
r220=سكني على الجهد 127/220ف
c220=تجاري على الجهد 127/220ف
r380=سكني على الجهد 220/380ف
c380=تجاري على الجهد 220/380ف
SAREA=بحث بالمساحة المشيدة
SCONNECTED=بحث بالاحمال الموصلة
v220=تغذية بـ220/127ف
v380=تغذية بـ380/220ف

[Label]
Sf=المساحة المشيدة م2
sc=الحمل الموصل ك.ف.أ
sc2=حمل الديماند ك.ف.أ
Scbamp=الحمل التعاقدي امبير
Scbkva=الحمل التعاقدي ك.ف.أ
srconn=اجمالي الاحمال الموصلة امبير
srcont=اجمالي الاحمال التعاقدية امبير

[menuform]
File1=ملف
Engneering1=الجداول
relationdept1=غرفة المحول
Exit1=الخروج
Option1=خيارات
skin=تغليف
noskin=بلاتغليف
ENGLISH=الانجليزية
ARABIC=العربية
Help=مساعدة
subhelp=ملف المساعدة
ABOUT1=عن البرنامج

[grid]
col0=
col1=
col1=

[msgbox]
mabout=
mmax=
mmin=
mtit=
0
 

Author Comment

by:sal1150
ID: 9692995

*[box]
sheet1=جداول احمال المشترك
sheet2=تحديد غرفة المحول
form1=ضوابط حساب احمال المشترك الجديدة والمعتمدة من الوزارة
typebox=انواع الجداول المقررة
sbox=خيارات البحث
resultbox=النتيجة
culbox=نتيجة الحساب

*[button]
cmdok=موافق
cmdcul=حساب
cmdclear=مسح

*[radio]
r220=سكني على الجهد 127/220ف
c220=تجاري على الجهد 127/220ف
r380=سكني على الجهد 220/380ف
c380=تجاري على الجهد 220/380ف
SAREA=بحث بالمساحة المشيدة
SCONNECTED=بحث بالاحمال الموصلة
v220=تغذية بـ220/127ف
v380=تغذية بـ380/220ف

*[Label]
Sf=المساحة المشيدة م2
sc=الحمل الموصل ك.ف.أ
sc2=حمل الديماند ك.ف.أ
Scbamp=الحمل التعاقدي امبير
Scbkva=الحمل التعاقدي ك.ف.أ
srconn=اجمالي الاحمال الموصلة امبير
srcont=اجمالي الاحمال التعاقدية امبير

*[menuform]
File1=ملف
Engneering1=الجداول
relationdept1=غرفة المحول
Exit1=الخروج
Option1=خيارات
skin=تغليف
noskin=بلاتغليف
ENGLISH=الانجليزية
ARABIC=العربية
Help=مساعدة
subhelp=ملف المساعدة
ABOUT1=عن البرنامج

*[grid]
col0=
col1=
col1=

*[msgbox]
mabout=
mmax=
mmin=
mtit=
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 5

Accepted Solution

by:
snehanshu earned 60 total points
ID: 9693130
sal1150,
  I must admit I have no clue of what the characters are :-(
  Can you write a simple test application which has just one group box and its caption is loaded from an inifile (A value you know that works for other controls) so that you know whether the problem is in the GroupBox control or the ini file you posted.
  And here's what I would I have tried: Since the form's caption looks a bit too long, I would place it at the end of the section and move the box captions above it in the inifile.
  THis is what I would make my box section look like:
[box]
sbox=خيارات البحث
resultbox=النتيجة
culbox=نتيجة الحساب
typebox=انواع الجداول المقررة
sheet1=جداول احمال المشترك
sheet2=تحديد غرفة المحول
form1=ضوابط حساب احمال المشترك الجديدة والمعتمدة من الوزارة

  If this doesn't help, then perhaps I have no idea. Let me know the results though.
...Snehanshu
0
 
LVL 5

Expert Comment

by:snehanshu
ID: 9822144
sal1150,
Were you able to solve the problem? How?
...Shu
0
 

Author Comment

by:sal1150
ID: 9828407

No,but I want to close the question...so I shift the points to you.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now