Locating and changing shapes on a preview from script
Hi. I have a question on using script with a report preview.
I see that I can toggle the color of a shape using:
I would now like to toggle an entire row of shapes using a click on another shape. I extended the code above to become:
Where can I find documentation that gives me the methods that I can call on shapes etc in script code?
Thanks
I see that I can toggle the color of a shape using:
procedure shpSelOnPreviewClick(Sender: TfrxView; Button: TMouseButton; Shift: Integer; var Modified: Boolean);
var
Shape : TfrxShapeView;
begin
Shape := TfrxShapeView(Sender);
If Shape.Color = clNone then
Shape.Color := clBlack
else
Shape.Color := clNone;
Modified := True;
end;
I would now like to toggle an entire row of shapes using a click on another shape. I extended the code above to become:
But I dont see any change. I seem to be locating the target shape (it shows up as a number in the debugger) but I dont know how to refresh it.procedure Shape1OnPreviewClick(Sender: TfrxView; Button: TMouseButton; Shift: Integer; var Modified: Boolean);
var
Shape : TfrxShapeView;
I : integer;
S : string;
begin
For I := 0 to 17 do
begin
S := 'shpR0C' + IntToStr(I);
Shape := TfrxShapeView(Page1.FindObject( S ));
If Shape <> nil then
begin
If Shape.Color = clNone then
Shape.Color := clBlack
else
Shape.Color := clNone;
end;
end;
end;
Where can I find documentation that gives me the methods that I can call on shapes etc in script code?
Thanks
Comments
same Problem here.
Doesnt Display in Preview. Any Solutions?
Thx in Advance