0
Ich habe eine Reihe von View-Controllern in der Scrollansicht, die mit Scrollview-Menüs verbunden ist. Wenn ich auf das Menü aus dem Menübalken klicke, zeige ich die respektierten Viewcontrollers an. aber alle View-Controller wurden anfangs geladen. Ich muss die View-Controller neu laden, wenn ich auf das entsprechende Menü klicke. Mein Code aussehen wieWie aktualisiere ich die Viewcontrollers in der Scrollview?
btnArray = @[@"Dashboard", @"Daily Log", @"Labour Timesheet", @"Work Safety", @"Soil", @"Equipment", @"Site Photos", @"Quick Links", @"Printable Forms"];
[self addButtonsInScrollMenu:btnArray];
DashBoardViewController *dashboardVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
DailyReportListViewController *dailyLogVC = [storyBoard instantiateViewControllerWithIdentifier:@"DailyReportListVC"];
TimeSheetListViewController *labourTimesheetVC = [storyBoard instantiateViewControllerWithIdentifier:@"TimeSheetListVC"];
SafetyReportListViewController *workSafetyVC = [storyBoard instantiateViewControllerWithIdentifier:@"SafetyReportListVC"];
DashBoardViewController *soilVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
DashBoardViewController *equipmentVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
DashBoardViewController *sitePhotosVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
DashBoardViewController *quickLinksVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
DashBoardViewController *printableFormsVC = [storyBoard instantiateViewControllerWithIdentifier:@"Dashboard"];
controllerArray = @[dashboardVC, dailyLogVC, labourTimesheetVC, workSafetyVC, soilVC, equipmentVC, sitePhotosVC, quickLinksVC, printableFormsVC];
[self addChildViewControllersOntoContainer:controllerArray];
Screenshot Ihrer Anforderung. – phani