How To Use Multiple View Controllers in Your iOS App - Swift 5 (Xcode 14 2023)

Поделиться
HTML-код
  • Опубликовано: 6 окт 2024

Комментарии • 117

  • @iOSAcademy
    @iOSAcademy  3 года назад

    Enjoy my teaching style? Learn to build the TikTok App from scratch with my course!
    ios-academy.teachable.com/p/building-tiktok-for-ios

  • @tranquility2400
    @tranquility2400 4 года назад +30

    I am an Android Developer with more than 4 years of experience, now I have just started working on iOS applications and trust me you have the best tutorials. Precise to be the point and clean easy to understand. Very well done.

    • @iOSAcademy
      @iOSAcademy  4 года назад +1

      Thanks! I really appreciate it :)

    • @divsyntax9720
      @divsyntax9720 Год назад +1

      Same. Droid dev learning iOS now.

  • @brunosousadeoliveira7050
    @brunosousadeoliveira7050 2 месяца назад

    I am a Android developer. However now I got in charge of the IOS too. I was having problems with those views presentation. You did good explanation about it. Thank you

  • @slash.9882
    @slash.9882 Год назад +1

    No BS, straight to the point and informative. It's exactly what I needed, thank you

  • @peterhimmelman9241
    @peterhimmelman9241 3 года назад +2

    I spent hours trying to figure out how to integrate the VC swift code along with a new VC from the storyboard and just could not get it! Your one point at the very start about simply making a new class within the primary VC file worked perfectly! So simple as well. Thank you!

  • @davidodia4603
    @davidodia4603 4 года назад +2

    It's always a nice intro to first show the viewers the finished application, before starting out. Kudos!

    • @iOSAcademy
      @iOSAcademy  4 года назад

      Yep, I personally like it a lot as well. I think its only fair to show you guys what you are getting into! Thanks

  • @moody54324
    @moody54324 4 года назад +3

    You deserve more subscribers to be honest and the idea behind uploading a video every day is awesome 😍♥️

    • @iOSAcademy
      @iOSAcademy  4 года назад

      Thanks! Growing 1 sub at a time

  • @jpv512
    @jpv512 2 года назад +2

    Nice presentation of how to link things from the basics, huge thanks !

  • @rdkutube
    @rdkutube Год назад

    Thank you! Likewise, I'm learning iOS and coming from android world and this was very helpful!

  • @ldomina9449
    @ldomina9449 2 года назад

    Thank you for the video! I'm new to swift UI and this video helped me to understand how to change the view!

  • @abdulbasir8740
    @abdulbasir8740 3 года назад +1

    Thank you brother

  • @Lambi91
    @Lambi91 4 года назад

    Thanks! I found out that I wanted to create an app that could help me register stuff.
    This helped me a lot! You just got yourself a new subscriber

  • @dollafome9317
    @dollafome9317 3 года назад +3

    Thank you so much! I was trying to figure this out for hours, but your video explained it in such an understandable way. Also, how would I link a second button on the first view controller to a third view controller?

  • @R86ER
    @R86ER 3 года назад +1

    iOS Academy > StackOverflow

  • @georges.154
    @georges.154 3 года назад +1

    SO HELPFUL! Thank you very much sir :)

  • @rochiellavina649
    @rochiellavina649 4 года назад +2

    I give an awesome 5 stars on this. Very clear explanation and no doubt of sharing ideas. On the future video tutorials more cool tips. I wish you can create another app like face detection camera (That will detect While balance surrounding, Track angles and Face Fit then trigger a auto capture from the camera save as image).

    • @iOSAcademy
      @iOSAcademy  4 года назад +1

      Thanks! Thats a great video idea, added to my list

    • @rochiellavina649
      @rochiellavina649 4 года назад

      @@iOSAcademy I cant wait to watch your tutorial again.
      Let me mention what app i referring to. Check this app (YouCam Makeup). Hope you can work similar part of the feature The Face Facial Detection.

  • @dugrut1325
    @dugrut1325 2 года назад

    Exactly what I wanted. Thank you

  • @philipr9945
    @philipr9945 Год назад

    I like the video. But I wish the screens wouldn't constantly zoom in and out. It's very distracting

  • @Christian031780
    @Christian031780 3 года назад +4

    I really like your tutorials, but as people mentioned before, you tend to zoom in and out too much unnecessarily which can make it hard to follow sometimes. Great tutorials man!

    • @iOSAcademy
      @iOSAcademy  3 года назад +3

      Thanks! New videos have no zoom :)

  • @dream_emulator
    @dream_emulator 2 года назад +1

    These are really excellent videos 👌

  • @hamandalygo
    @hamandalygo 2 года назад +1

    Liked and subscribed :)

  • @nurlanakylbekov7266
    @nurlanakylbekov7266 3 года назад

    I was thinking of this tutorial about put the second view controller into first view controller

  • @kgcolor
    @kgcolor 4 года назад +2

    u r my hero

  • @maryrooster8737
    @maryrooster8737 3 года назад +1

    Thanks for this video, it was very helpful! Would it be possible to do less zooming in and out (or zoom but not as close or far away)? It can give viewers vertigo.

  • @clude9897
    @clude9897 4 года назад +1

    Absolute hero. Thank you!

  • @danielgoldberg7473
    @danielgoldberg7473 2 года назад

    not me SMASHING the like button

  • @SpykeHacks
    @SpykeHacks 4 года назад +2

    How would you make it so it isn't stacked? For example, if I want to bring up a viewcontroller that only appears on the first open, then once they read that view controller, it transitions into the regular app. That shouldn't be stacked, how would you go about that? Thanks!! Also subbed for great content.

    • @iOSAcademy
      @iOSAcademy  4 года назад +7

      Firstly, thanks for the sub! For doing something like this there are a few approaches. The first thing you are asking about is how to pop up a new controller without seeing the one behind it. This is done through assigning the presentationStyle property on the viewcontroller. You want the .fullscreen value. Take a look here developer.apple.com/documentation/uikit/uipresentationcontroller/1618320-presentationstyle
      Second, for something like the example you gave - say a welcome flow in the app before the main app, you could present a controller in full screen style, and once you dismiss, it reveals the main app. This is a cool idea for a video I may do though!

  • @George-yk9xi
    @George-yk9xi 4 года назад +2

    Thank you a lot!

    • @iOSAcademy
      @iOSAcademy  4 года назад

      Youre welcome! Make sure to subscribe for more!

  • @dadrewco100
    @dadrewco100 3 года назад +1

    Thanks ! You are the best !

    • @iOSAcademy
      @iOSAcademy  3 года назад +1

      Youre welcome! Make sure to like & subscribe

    • @dadrewco100
      @dadrewco100 3 года назад

      @@iOSAcademy done !

  • @JackWutang
    @JackWutang 4 года назад +5

    What if you want the new screens to take up the whole screen instead of showing up as stacked "cards"?

    • @iOSAcademy
      @iOSAcademy  4 года назад

      For this, on the viewController, you need to assign the presentationStyle property which is an enum. The value you are looking for is .fullscreen. Here is a ref: developer.apple.com/documentation/uikit/uipresentationcontroller/1618320-presentationstyle

    • @nomadqaderi9847
      @nomadqaderi9847 4 года назад +1

      You need to change the presentation style to full screen from the Identity inspector. Let me know if you need any help with this :)

    • @bury1532
      @bury1532 4 года назад

      @@nomadqaderi9847 I'm trying and still don't know how to do it... ??? :/

    • @jonasgrn4282
      @jonasgrn4282 4 года назад

      @@bury1532 What you wanna do is most likely this line before you present your view: vc.modalPresentationStyle = .fullScreen

  • @nguyenquockhang117
    @nguyenquockhang117 Год назад

    Hi, I like the video but the Tittle is misleading. It is not Xcode 14 2023.
    Could you please update it?

    • @iOSAcademy
      @iOSAcademy  Год назад

      Ill be making an updated video

  • @hammam92
    @hammam92 Год назад

    Amazing. Which software you used in this video in order to record the screen? Thank you.

    • @iOSAcademy
      @iOSAcademy  Год назад

      No problem

    • @hammam92
      @hammam92 Год назад

      @@iOSAcademy can you please tell me the program you use for recording the screen?

  • @nicolacuomo8914
    @nicolacuomo8914 4 года назад +1

    Hi, beautiful videos thanks. But how I can do the same with Swift UI?

    • @iOSAcademy
      @iOSAcademy  4 года назад

      Thanks! SwiftUI videos coming soon!

  • @11mroscar
    @11mroscar 4 года назад

    for some reason my view controller is not shown on the custon class its so fustrating. Would u be able to help also great video!

  • @sethcalderon8195
    @sethcalderon8195 4 года назад +1

    Yo how do you hop around in Xcode like that? I am very new to Xcode, could you spare some tips and tricks?

    • @iOSAcademy
      @iOSAcademy  4 года назад

      Ill make a video on this!

  • @konstantin2387
    @konstantin2387 2 года назад

    Just one question: is your mouse broken? Why do you alsways search for the view controller with "cmd+space"??

  • @OnionKnight541
    @OnionKnight541 Год назад

    An interesting problem I've encountered is when created VCs, the embedding can get weird. The VC has a "safe area" and it wants to put space for a navigation controller above that, but sometimes that extra space isn't needed. Have any idea how that issue occurs?

  • @riffatkhan6006
    @riffatkhan6006 2 года назад

    can you plz tell me what is the type of GreenViewController next to as! . I mean if we want to make function to go new view controllar we can set identifier as a parameter bcoz we konw its of string type but what we will write for vc name that you give as GreenViewController

  • @rand-em6zi
    @rand-em6zi 4 года назад +2

    What key strokes are using to hop into main story board at 2:23

    • @iOSAcademy
      @iOSAcademy  4 года назад +2

      CMD+Shift+O = project wide search menu :)

    • @rand-em6zi
      @rand-em6zi 4 года назад

      @@iOSAcademy Thank you :)

  • @michaelt9241
    @michaelt9241 3 года назад +1

    Is there another function you can use apart from "present" as I want the viewcontroller to take over the screen.

    • @iOSAcademy
      @iOSAcademy  3 года назад

      Push for nav controllers

    • @michaelt9241
      @michaelt9241 3 года назад

      I just found out I could change the `modalPresentationStyle` of the view to `.fullScreen`. Trying to figure out at the moment how to handle JSON responses from a GET request. (new to swift/ ios dev)

  • @dugrut1325
    @dugrut1325 2 года назад

    I put code in the SecondViewController eg. nothing worded or displayed, it was like a dead zone, how do you access this area???

  • @coonnaarr1984
    @coonnaarr1984 3 года назад

    How can I change it, so the new screen isnt "infront" I dont want the old screen to be seen behind it

  • @tsingh7275
    @tsingh7275 4 года назад

    Can you have more than 2 view controllers and have the same transition?

  • @HirenMistry0125
    @HirenMistry0125 4 года назад

    hello sir,
    what should i do to open a tableview when click button?

  • @cc0561
    @cc0561 2 года назад

    I’m trying to use vc but I keep getting a error message every time I use it

  • @ManishPatel-fb5ee
    @ManishPatel-fb5ee 3 года назад

    Hi, the textfield on my second viewcontroller is not working! Any suggestions on how to make it so I can select and enter text in my second view controller? It works for my first/main

  • @scubasteve117
    @scubasteve117 Год назад

    So the apps that Xcode generates don't seem to be structured anything like the apps his tool is generating, is he using an old out of date version of Xcode?

    • @iOSAcademy
      @iOSAcademy  Год назад

      It depends what settings you pick. The biggest difference is swiftui vs. storyboard

  • @user-rf4vc7mt4d
    @user-rf4vc7mt4d 3 года назад

    Is there a function I can write in the secondary view controller to close it?

  • @gamingspieler2423
    @gamingspieler2423 3 года назад

    Hey Bud Its Working but how to implement the same using
    navigationController?.pushViewController(vc, animated: true)
    thanks

  • @carneiro.fernando
    @carneiro.fernando 4 года назад

    HELP ME! How can I change that swipe scene (present VC) to normal scene, closing the view before open the next??

  • @ezstudio3d
    @ezstudio3d 3 года назад

    how can I run the present code from a URLSession.dataTask?
    nevermind I found it DispatchQueue.main.async() {
    // your UI update code
    }

  • @lulup5913
    @lulup5913 3 года назад

    I get an error for the @IBAction part. What should I do?

    • @iOSAcademy
      @iOSAcademy  3 года назад

      Whats the error? Is your syntax right?

  • @107087
    @107087 4 года назад

    I'm curious why you had the didTap ruction. I created a new viewController and swift file and ctrl+dragged a button to the new VC. It performs the same "touch up inside" without ever connecting the button to a function or even declaring the button in the original VC. thoughts?

    • @iOSAcademy
      @iOSAcademy  4 года назад

      I think doing it in code helps you learn more and in professional large scale projects, we don't control drag or use storyboard much

    • @107087
      @107087 4 года назад

      @@iOSAcademy hi. thanks. I meant to say I never made it an action---just tied the button from one VC to the next.

  • @superblaubeere27
    @superblaubeere27 4 года назад +1

    Can you please stop those zooms. They are more annoying than they help

  • @marblERkin
    @marblERkin 3 года назад

    doesn't work

  • @sheldoncup896
    @sheldoncup896 4 года назад +1

    You need to stop zooming into that mouse, ffs!

  • @phpnotasp
    @phpnotasp 3 года назад +1

    So much unnecessary zooming. Please stop before I get motion sickness.

    • @iOSAcademy
      @iOSAcademy  3 года назад

      Haha new videos dont have zoom

  • @vladut-alexandrualexe2785
    @vladut-alexandrualexe2785 4 года назад

    marfa clipu

  • @raymundoortiz7269
    @raymundoortiz7269 2 года назад

    if you knew that there is high definition in youtube videos, you wouldn't make us dizzy with so much zoom in and zoom out

    • @iOSAcademy
      @iOSAcademy  2 года назад +1

      New videos have no zoom 🙃

  • @harpermartin7813
    @harpermartin7813 3 года назад

    Jesus loves you all! If you do not know Him as savior, please ask Him to save you.
    John 3:16
    “For God so loved the world that He gave His one and only begotten Son that whoever believes in Him shall not perish but have everlasting life.”
    Amen to that! Thank You Jesus! Thank You God!
    If you want to read the Bible you can download the free YouVersion app.

  • @urladyswidme
    @urladyswidme Год назад

    Terrible view baiting. This is not how you do it with Xcode 14

  • @johnalejandrogarciaarias9756
    @johnalejandrogarciaarias9756 4 года назад +1

    Very useful! Thx mate! Excellent explanation.

    • @iOSAcademy
      @iOSAcademy  4 года назад +1

      Your welcome! Make sure to subscribe

  • @mitchroworth6542
    @mitchroworth6542 4 года назад

    What do I do if the swift file does not come up in the lookup? I am new to xcode and haven't quite got the hang of everything just yet. Hoping someone will be able to help? Cheers in advance

    • @107087
      @107087 4 года назад

      do you mean when you're assigning the custom class? If so, did you scroll downward--as opposed to typing the name?

  • @gyos23
    @gyos23 4 года назад

    How do you get the spotlight search in Xcode? I tried CMD + F. Its not how you're searching.