Post

Replies

Boosts

Views

Activity

Reply to How can I display a text typed in Textfield on first view (page) to second view (page)?
The way you call your AccountRegistrationView information on your ConfirmationView it will always return a copy of the AccountRegistrationView with all the info as per their initial values i.e. userName = "" email = "" pass = "" What you need to is place the variables to be updated in your ConfirmationView as variables, see below: struct ConfirmationView: View { var userName: String var email: String var pass: String var body: some View { Text("User name: \(userName)") .multilineTextAlignment(.center) .padding(.all, 20.0) Text("Email address: \(email)") .multilineTextAlignment(.center) .padding(.all, 20.0) Text("Password: \(pass)") .multilineTextAlignment(.center) .padding(.all, 20.0) } } and your NavigationLink should be: NavigationLink { ConfirmationView(userName: userName, email: email, pass: pass) } label: { Label("Next", systemImage: "arrowshape.forward.fill") .font(.body) }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Jun ’23
Reply to How to export a View in multiple A4 PDF pages?
No one ever faced the same issue? 😳
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’23
Reply to How can I display a text typed in Textfield on first view (page) to second view (page)?
The way you call your AccountRegistrationView information on your ConfirmationView it will always return a copy of the AccountRegistrationView with all the info as per their initial values i.e. userName = "" email = "" pass = "" What you need to is place the variables to be updated in your ConfirmationView as variables, see below: struct ConfirmationView: View { var userName: String var email: String var pass: String var body: some View { Text("User name: \(userName)") .multilineTextAlignment(.center) .padding(.all, 20.0) Text("Email address: \(email)") .multilineTextAlignment(.center) .padding(.all, 20.0) Text("Password: \(pass)") .multilineTextAlignment(.center) .padding(.all, 20.0) } } and your NavigationLink should be: NavigationLink { ConfirmationView(userName: userName, email: email, pass: pass) } label: { Label("Next", systemImage: "arrowshape.forward.fill") .font(.body) }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’23
Reply to WeatherKit Issues? (401, NOT_ENABLED, etc.)
Hi, just to share that although I managed to implement WeatherKit in my App, it seems that every now and then I get "WeatherDaemon.WDSClient<WeatherDaemon.We atherResource>.Errors error 1" . I just switched from OPEN-METEO thinking that Apple's WeatherKit would be more stable...boy I was wrong...
Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
May ’23