How can I get rid of this error ?
import SwiftUI
@main
struct Project_Health_calculatorsApp: App {
var body: some Scene {
WindowGroup {
ContentView() // <- error is here
}
}
}
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I can't fix this error.
Cannot convert value of type '[Double]' to expected argument type 'Double'
let someValue = Double(SomeValue / SomeValue) // error is here
There has been an error that sometimes repeats itself. How can I remove it?
Struct Name: View {
some data ...
Struct ContentView: View {
... some data
struct ContentView_Previews:
PreviewProvider {
static var previews: some View {
ContentView()
}
}
struct Name: View { // <- inwalid redeclaration of Struct Name
var body: some View {
Text("Name")
}
}
struct Name: View { // // <- inwalid redeclaration of Struct Name
var body: some View {
Text("Name")
}
}
An error appears and I don't know how to solve it : Closure containing a declaration cannot be used with result builder 'ViewBuilder'.
import SwiftUI
Struct ContentView: View {
var body: some View {
// some code...
struct ContentView_Previews: PreviewProvider { // <- error Closure containing a declaration cannot be used with result builder 'ViewBuilder'.
static var previews: some View {
ContentView()
}
}
Struct Name: View {
// some code ...
var body: some View {
Text"some text"
// some code ...
Struct Name: View {
var body: some View {
Text"some text"
Struct Name: View {
var body: some View {
Text"some text"
I have error: Cannot convert value of type 'Binding<String>.Type' to expected argument type 'Binding<String>'
I am using Xcode version 12.3, swift 5 and iOS 14.3
Occurred when grouping static containers (TextField and Text)
struct ContentView_Previews: PreviewProvider {
static var previews: some View {
ContentView(text: Binding<String>) // error is here
}
}
How can I solve this ?
Hello, how can I find the alpha channel to uncheck it, because I can't upload the build, before uploading to the app store ?
Hello, how can I resolve this error ?
Cannot convert value of type 'Binding<[Video]>.Type' to expected argument type 'Binding<[Video]>'
NavigationLink(destination: SomeView.init(data: Binding<[Video]> ... // error is here
What example argument can I give in place of (date: Binding),?
Hi, how can I remove this error ?
Type 'SomeView' does not conform to protocol 'View'
struct SomeView: View { // here is error
Hello, how can I get rid of this error ?
Type of expression is ambiguous without more context
var body: some View {
NavigationView { // error is here
Form {
Group {
List {
VStack {
NavigationLink(<Text>(VStack {
ScrollView(.vertical) {
VStack(spacing: 13) {
ForEach(0..<1) {_ in TextField("Enter hour",text:$checknewHour
.keyboardType(.decimalPad)
.font(.system(size: 25)), Text("\(checknewHour) $ Hour")
.foregroundColor(.purple)
.font(.system(size: 25)),TextField("Enter minute",text:$checknewMinute
.keyboardType(.decimalPad)
.font(.system(size: 25)), Text("\(checknewMinute) $ Minute")
.foregroundColor(.purple)
.font(.system(size: 25)),
I have created custom colors but I don't know how to save these views in the application so that the colors in background and foreground change according to the custom color change.
How can I do this ?
I was setting custom colors and got an warning: Color set has an unassigned color child.
What can I do ?
How can I write notification code regarding entering correct numbers in text field ?
I would like to remove the code error: cannot use instance member 'number' within property initializer; property initializers run before 'self' is available from code:
let number = "some number"
let absolute = abs(number) // Here is error
What is the difference between iPhone simulator screenshot
from the application preview screenshot visually ?
How to take iPhone simulator screenshot and app preview screenshot in Xcode 12.4 ?