Menu

Use a Frame or a Form?

Bryan
2014-02-03
2014-05-05
  • Bryan

    Bryan - 2014-02-03

    I see from the demos you can assign a frame to a ViewController. I see also you can assign a form?
    This is good to separate out the code into different units, but I'm not sure which one I should use.

    Should I use a Frame or Form? Are there any advantages or disadvantages (memory, performance etc...)
    Sorry for all the questions lately, I'm trying to learn this iOS stuff.

    Thanks!
    Bryan

     
  • Babak Yaghoobi

    Babak Yaghoobi - 2014-02-03

    Hi Bryan

    I strongly recommend to use Frame instead of Form,
    Using Frame is : High performance, low memory usage, ...

    Regards

     
  • Bryan

    Bryan - 2014-02-03

    Thanks again Babak!

     
  • Gordon

    Gordon - 2014-02-04

    My apps normally assign all of the frames at start.. then, I design all of my code in a ONE unit per frame.. makes coding so easy.

     
  • Bryan

    Bryan - 2014-05-03

    Hello,
    I'm starting to get into frames with my app to separate out the logic like Babak and Gordon suggests, but I'm having a problem.
    I would like to have a page control and with each page have a frame.
    For some reason I can't do this.

    I've dropped a DPFUIPageViewController on the form. Added pages, but I can't seem to assign a frame to the pages?

    Any suggestions?
    Thanks!
    Bryan

     
  • Gordon

    Gordon - 2014-05-04

    In my Formshow, on my main form,, I do..

    LoginPage.Frame := TLoginFrame;
    MainMenuPage.Frame := TMainMenuFrame;
    OrderViewPage.Frame := TOrderViewFrame;

    Once assigned, I just maintain my code in separate units, one for each frame. Makes the code easy.

    Maybe what you are trying to do, is assign them in/on the component? You have to do it in code..

     
  • Bryan

    Bryan - 2014-05-04

    Thanks Gordon,
    What kind of controls are your LoginPage, MainMenuPage and OrderViewPage? Are they pages of a DPFUIPageViewController? Maybe I'm just using the wrong control?

    I've looked at DPFUIPageControl also, and I can see where I can set the number of pages and I can set the current page, but if I put a label on the PageControl, then I set the CurrentPage to something different, it still shows the label.

    Sorry, still confused.
    Bryan

     
  • Bryan

    Bryan - 2014-05-04

    I've also looked at the PageControl demo. It's not much help. I can see there are 5 pages set in the NumberOfPages property and I can see the 5 dots at the top of the control, but how do you "view" the pages?

    Sorry for all the questions. I think I'm stuck in Win32 mode with the controls and don't see the "light" for the iOS PageControl.

     
  • Gordon

    Gordon - 2014-05-04

    is there a demo you can send me to play with? I would mind playing with it..

    Gordon

     

    Last edit: Gordon 2014-05-04
  • Bryan

    Bryan - 2014-05-04

    Hi Gordon,
    I really appreciate your help. I think it comes down to I'm not sure I'm using the correct component for what I'm trying to do.
    I've attached a very small sample.
    Regards,
    Bryan

     
  • Gordon

    Gordon - 2014-05-04

    what is your reasoning for using a pagecontrol v.s. navcontroller in this case?

     
  • Bryan

    Bryan - 2014-05-04

    Hi Gordon,
    I have no reason. I think it is because I don't know which one to use. So I guess I should be using NavController?

    Bryan

     
  • Bryan

    Bryan - 2014-05-05

    Hi Gordon,
    Thanks for the suggestion on the NavController. I think this will work for me.

    Bryan

     
  • Fenistil

    Fenistil - 2014-05-05

    Hi Bryan!

    Check out this post, here I wrote a sample how to do what you want.

    Greetings

     
  • Bryan

    Bryan - 2014-05-05

    Hi Finistil!
    Thanks for the link. I'm on the right track now thanks to you and Gordon.

    Regards,
    Bryan

     

Log in to post a comment.