I need a Switch inside (on right side) of a few of my TableViewItems.
I've tried with no luck....
Here's my setup.
I have 3 switches on the main form. Name = switchF0, switchF1, switchF2
In my tableview section[0], I have 6 items. On the first 3 items (0-2), I want to push a switch in the TableViewItem on the right side.
The TableViewItem AccessoryView is set to the switchF0 and I've tried several AccessoryType selections, but I can never get the switch to show up on the TableViewItem.
begin
if uiViewMain.Position.X < 200 then
begin
//slide the view to the right
uiViewMain.SetBounds(uiViewMain.Position.X, uiViewMain.Position.y, frmMain.Width, frmMain.Height);
TUIView.OCClass.beginAnimations(nil, nil);
TUIView.OCClass.setAnimationDuration(0.4);
uiViewMain.SetBounds(300, 0, frmMain.Width,frmMain.Height);
TUIView.OCClass.commitAnimations;
end
else
begin
//slide the view to the left
uiViewMain.SetBounds(uiViewMain.Position.x, uiViewMain.Position.y, frmMain.Width,frmMain.Height);
TUIView.OCClass.beginAnimations(nil, nil);
TUIView.OCClass.setAnimationDuration(0.4);
uiViewMain.SetBounds(0, 0, frmMain.Width,frmMain.Height);
TUIView.OCClass.commitAnimations;
end;
end;
We have tested this here and we are successfully able to display the three switches. Can you perhaps send us your sample project so we can investigate this here?