Search code examples
iosaqgridview

IOS- load two AQGridView in UIViewControler


now i load one AQGridView in UIViewController, its working good, but i want load one more AQGridView, i dont know how, somebody help me, thanks you for read this article


Solution

  • You just instantiate a new instance of an AQGridView and add it as a subview to the UIViewController's View. It's hard to get much more specific than that without more information from you. It should look something like this:

        AQGridView *gridView = [[AQGridView alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width/2, self.view.frame.size.height)];
        gridView.dataSource = self;
        gridView.delegate = self;
        [self.view addSubview:gridView];
    

    Then you'll need to configure the grid view with the data source and delegate methods just like you do the first one.