Project JEDI - Issue Tracker
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0004471 [JEDI VCL] 00 JVCL Components crash always 2008-09-22 15:02 2008-10-10 05:09
Reporter _R_Vital View Status public  
Assigned To obones
Priority normal Resolution fixed  
Status resolved   Product Version 3.34
Summary 0004471: TJVDBRadioPanel don´t show corretly information when EVENTS GET/SET text are present
Description My English is bad, so, i'll try to make myself clear!

When TJvDBRadioPanel is linked in a field, and this same field have a code in events GET and SET Text to translate the information from the database to user, ex: MALE = M, FEMALE = F, the radiopanel don´t show any radiobutton marked. I have tried with others radiobuttons (VLC radiogroup for example, InfoPower, VGLib...) and that problem don´t occours. The Itens property contains "Male,Female" and the Values Property contains "Male,Female". Both are the same! If I change Property values to "M" and "F" the radiopanel show the information corretly but don´t save in database. I hope to find a solution very soon with your´s helps and i hope make my explanation very clear as possible with my "lazy" english =)

Regards from Brasil;

RvMello
Additional Information procedure TdmD.tblMembersSEXGetText(Sender: TField; var Text: String; DisplayText: Boolean);
begin
 If Sender.AsString = 'M' then
  Text := 'Male';
 If Sender.AsString = 'F' then
  Text := 'Female';
end;

procedure TdmD.tblMembesSEXSetText(Sender: TField; const Text: String);
begin
 If Text = 'Male' then
  Sender.AsString := 'M';
 If Text = 'Female' then
  Sender.AsString := 'F';
end;
Tags No tags attached.
Attached Files

- Relationships
has duplicate 0004470resolvedobones TJVDBRadioPanel don´t show corretly information when EVENTS GET/SET text are present 

-  Notes
(0014645)
_R_Vital (reporter)
2008-09-23 11:57

I solve the problem, simple adding the :

" and (FItemIndex<FButtons.Count) "

on line:

if (FItemIndex >= 0) then

So,

if (FItemIndex >= 0) and (FItemIndex<FButtons.Count) then

This is a entire procedure, for your´s ...

procedure TJvDBRadioPanel.UpdateButtons;
var I: Integer;
begin
  SetButtonCount(FItems.Count);
  for I := 0 to FButtons.Count - 1 do
    TGroupButton(FButtons[I]).Caption := FItems[I];
   if (FItemIndex >= 0) and (FItemIndex<FButtons.Count) then
  begin
    FUpdating := True;
    TGroupButton(FButtons[FItemIndex]).Checked := True;
    FUpdating := False;
  end;
  ArrangeButtons;
  Invalidate;
end;
(0014669)
jfudickar (developer)
2008-09-24 14:50

Added your fix to svn.

Please have a look for it.

Greetings
Jens
(0014814)
obones (administrator)
2008-10-10 05:07

This is in SVN

- Issue History
Date Modified Username Field Change
2008-09-22 15:02 _R_Vital New Issue
2008-09-22 23:42 obones Relationship added has duplicate 0004470
2008-09-23 11:57 _R_Vital Note Added: 0014645
2008-09-24 14:50 jfudickar Note Added: 0014669
2008-09-24 14:50 jfudickar Status new => feedback
2008-10-10 05:07 obones Status feedback => resolved
2008-10-10 05:07 obones Fixed in Version => Daily / SVN
2008-10-10 05:07 obones Resolution open => fixed
2008-10-10 05:07 obones Assigned To => obones
2008-10-10 05:07 obones Note Added: 0014814


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker