Question

HI,

I created 4 radiobuttons in a intraweb application. One is checked by default, the rest is not. The belong to the same group called group. (I set the group properly of each TIWradiobutton)

There is twiimage image which has click event. In that click event, I tried to set the radiobuttons. E.g. radiobutton1.checked:=true;

The problem is that this sometimes set the radiobutton and sometimes it does not.

I found a fix by setting the rest of radiobuttons.checked to false. That fixed the problem.

I wonder what I did wrong in the first place when I just used one assignment.

Can you tell me if it is a bug in intraweb or I used radiobutton improperly?

Thanks.

No correct solution

OTHER TIPS

just create a IWRadioGroup1(in iwstanderd pallet ) in your form

select IWRadioGroup1 , in the properties panenel dblclick on items

you will get a stringlist editor ,type the captions of your four radiobuttons line by line then click OK

now select your IWImage1 ,goto click events just type th above code

procedure TformMain.IWImage1Click(Sender: TObject);
begin
IWRadioGroup1.ItemIndex := 2 // 2 is the radiobutton number as you typed in stringlist editor
end;

sometimes IW or components build over the IW (e.g TMS suite for IW) have a strange behavior.you can find how it works by looking out in the code, how they manage the java script behind your radio groups.

Also sometimes you must manage the components exactly how Atozed say in their documentation.

Probably isn't the best answer, but if you'll work a lot with IW you'll see that it has a lots of limitations and strange behavior (only if you don't work in their style, which sometimes differs a lot from win32 style).

best regards,

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top