Category "swift"

Not getting Razor pay Signature and Order ID in iOS

I have integrated the code of Razor pay, but after adding Order_id which I got from Web service Response, I am just getting Payment Id, but not getting Razor pa

Make TextField autosearch when map is opening

I have a TextField at the top of my map in Xcode. The map is opening when you choose food, to find the nearest restaurant. I want TextField to search for the St

Accessibility Inspector not working on Xcode Version 13.3 on macOS Monterey Version 12.3

I launch the Accessibility Inspector from within Xcode but it doesn't let me interact with elements in the simulator. I relaunched Xcode, the Accessibility Insp

CAShapeLayer Image Not Appearing

I have an image.cgImage that I set as the contents to a CAShapeLayer() but it's not appearing. I force unwrap the image so I know that it definitely exists. The

How do I detect when User has reached the bottom of the ScrollView?

I used the following code as a reference: SwiftUI - Get size of child? SwiftUI - How to get size (height) of ScrollView content Get the current scroll position

Xcode 12.5 dyld issue with binary frameworks

I have a binary Swift xcframework which references two other open-source Swift frameworks (built from source). My framework along with its dependencies are buil

How to display SVG Templates in SwiftUI

I am trying to display an SVG Template in my SwiftUI app. So, I have a var svgTemplate: String variable in my SwiftUI App that contains an SVG Template string,

KMM IncorrectDereferenceException in Thread

I have been trying to upload an image to aws s3 server using shared module KMM. It works very well in Android but in iOS I have been getting this issue :- Uncau

An error occurs when using MLDataTable to load data

I tried to create a word tagger model in Swift according to this tutorial in the latest XCode. But I cannot load data from a local file using MLDataTable. Here

Notification Center Selector Method does not get called

Hi I've HomeCollectionViewCellComponent which is using in HomeCollectionViewCell and also there is a struct that holds size calculation logics for my collection

Return a dictionary from multiple line string in swift

I am new to swift. Is there a simple way to convert the following string to dictionary format. Example: input = "Name: Jack\\n Area: Place\\n FavColor: Blue\\n"

Thread 4: Fatal error: 'try!' expression unexpectedly raised an error

I'm trying to learn to make an API call in swiftUI, I'm following the next tutorial https://www.youtube.com/watch?v=1en4JyW3XSI but the code is giving me an err

Getting Localized string not found in wkwebview

Please provide if there any solution

tvOS Table View layout Issues

I am using tableviews in my tvOS application. The screen is divided into 3 table views. The left and right table view is indenting the header, the middle has no

AWS Amplify Flutter: how to create platform endpoint?

Short version of my question: I have a Flutter mobile app that uses AWS Amplify to handle user sign-up and log-in. Now I need to add push notification capabilit

SharingMusicPlayer.swift:12:79: Cannot convert value of type 'AVAudioPlayer.Type' to expected argument type 'AVAudioPlayer'

This is what I have in my singleton: import AVFoundation import Foundation class SharingMusicPlayer { static let sharingMusicPlayer = SharingMusicPlayer(ba

What is "SwiftPM.SPMRepositoryError error 5"?

I've searched Apple's documentation, open source projects, and Google, and I cannot seem to find any information about SwiftPM.SPMRepositoryError error 5. Heck,

Restoring macOS window size after close using SwiftUI WindowsGroup

By default, on a macOS app using SwiftUI the window size is not restored after the window is closed. Is there a way to keep whatever size & position the use

How to create a ZkSync account?

The ZkSync documentation states that a deposit has to be made from an existing Ethereum account to a non-existing ZkSync account counterfactually in order to cr

How to execute a CPU-bound task in background using Swift Concurrency without blocking UI updates?

I have an ObservableObject which can do a CPU-bound heavy work: import Foundation import SwiftUI @MainActor final class Controller: ObservableObject { @Pub