I am having a problem setting the TTIWOutlookBar ActivePage.
When I click an Item on a TTIWOutlookBar I want the page of that item to remain the active page.
My app code:
procedure TIWFrameMainMenu.Move(AFormClass: TIWAppFormClass);
begin
// Do not allow form reload
if AFormClass.UnitName = TIWAppForm(WebApplication.ActiveForm).UnitName then
Exit;
// Release the current form
TIWAppForm(WebApplication.ActiveForm).Release;
// Create and Show the move-to form
AFormClass.Create(WebApplication).Show;
end;
procedure TIWFrameMainMenu.TIWOutlookBar1ItemClick(ASender: TObject; Panel: TIWOutlookPanel; Item: TIWOutlookItem);
var
lv_PI
:Smallint;
begin
lv_PI := Panel.Index;
// TIWOutlookBar1.ActivePanel := lv_PI; //for test only
case Panel.Index of
0: //Installation Manager
case Item.Index of
0: //Setup
begin
Move(TIWFormInstallationSetup);
end;
end; //case
1: //System Manager
case Item.Index of
0: //setup
begin
WebApplication.ShowMessage('NYI');
end;
1: //Lookuo lists
begin
Move(TIWFormLookupLists);
end;
end; //case
2: //Application Manager
case Item.Index of
0: //setup defaults
begin
Move(TIWFormApplicationSetups);
end;
end; //case
3: //station Manager
case Item.Index of
0: //setup
begin
Move(TIWFormStationSetups);
end;
end; //case
4: // Users
case Item.Index of
0: // Permissions
begin
WebApplication.ShowMessage('NYI');
end;
1: // Forms
begin
WebApplication.ShowMessage('NYI');
end;
2: // Reports
begin
WebApplication.ShowMessage('NYI');
end;
end; //case
5: //Alerts
case Item.Index of
0: // Setup
begin
WebApplication.ShowMessage('NYI');
end;
end; //case
6: //Reports
case Item.Index of
0: // Reports
begin
WebApplication.ShowMessage('NYI');
end;
end; //case
end; //case
// ResetButton1(Sender);
TIWOutlookBar1.ActivePanel := lv_PI;
end;
**********
The second time I click an item the correct panel stays active
TIA
Zane
I have not been able to reproduce this issue.
Can you please explain exactly how to reproduce this or provide a ready to use sample project that demonstrates the issue?