Thanks for the suggestion and help.Really do appreciate it as this has gotten extremely frustrating compared to using storyboards.I did figure it out. I used the example from youtube:https://www.youtube.com/watch?v=bqr5NidImk0and that seemed to work on my phone (still something wrong with the simulator.)I'm now on to the point where I'm trying to share data bewtween the 2 views...needless to say this is another very NEGATIVE experianece. In story board I could get this whole app done in an hour.now I'm fighting with the most basic of things like global variables not working or printing or updating correctly.to be quite blunt, I think swift UI is straight garbage. and it's a good thing for the people that developed this that Steve Jobs isn't around anymore. Otherwise they would get fired for incompetence (and rightfully so). I and customers don't have time (or the money to pay for that time) to fight with things and deal with 50 steps for something that should take 1 step. Either way, sorry to vent at you and I do appreciate your suggestion and help.
Post
Replies
Boosts
Views
Activity
GOT IT! Finally!Text("\(PercentageValue, specifier: "%.2f")")Suggestion is have things like specifier, come up in the drop down/type ahead stuff.
Ok,realize the mistake in the above code.However, still doesn't work.I get the infamous can't convert int to cgfloat error.Code should be down in the lable section:var body: some View { VStack{ Button(action: { if (self.image == nil) { self.showingImagePicker.toggle() } else { print("Image Selected") //New_more_other code here } }) { if (image == nil) { VStack { Image(systemName: "square.and.arrow.down.fill") .resizable() .frame(width: 150, height: 150) Text("No Image specified\n Select Image") } } else { Image(uiImage: image) .resizable() .frame(width: 150, height: 150) } } }.sheet(isPresented: $showingImagePicker, content: { ImagePicker.shared.view }).onReceive(ImagePicker.shared.$image) { image in self.image = image } }ANY help would be appreciated as I can not tell what I'm doing wrong here.
ya, I was able to finally find that %.2f on stack overflow.Took me several hours, and I was extremely frustrated with it at that point.Thanks for the help.