Questions tagged as 'swift'

1
answer

Query sqlite database created by core data

I'm studying the core date in ios. I created a template and inserted some records. I would like to query these records using SQL in the program "DB Browser for sqlite", but I do not know where xcode creates the database file. Anyone know?     
asked by 31.12.2016 / 05:00
2
answers

How do I get a return of an ArrayString on a GET call with task.resume ()?

Good afternoon, everyone. I'm having trouble loading the contents of a PickerView into my app, because for this it needs to fetch the information on a GET call, the call works and I can set array to the content I need, but I can no...
asked by 29.10.2015 / 20:12
1
answer

How to calculate the distance between two location points?

I need to calculate the shortest distance between two locations obtained automatically through CoreLocation . To be more specific, the idea is to mark a starting point and after the user "walk" a little, I need to calculate the distance...
asked by 22.06.2015 / 15:26
2
answers

Integration of JSON with Swift

I wanted to know how I get to pass a JSON with my URL to Swift. I have an example: link and if anyone can start my JSON in the Swift language already it would help me a lot because I can not get out of the place. So, in my company we ha...
asked by 15.12.2014 / 12:57
2
answers

Auto layout iOS does not work correctly Xcode 8.2

I'm developing an App in Xcode 8.x. I have a problem resizing 4 buttons on the first screen. I work on the design of iPhone 5 or 6 and I set up all the auto layout, when I squeeze all the devices it's cool except on the Iphone 4 where I can o...
asked by 01.11.2017 / 01:44
2
answers

How to share a pdf that is in a webview in Swift

I have a webview and I call it an address that if accessed by a browser forces a download of a PDF, in the app I created I loaded the PDF in a webview, but I would also give the user the option to share this PDF by e- mail, send to IcloudDrive,...
asked by 30.03.2017 / 16:54
5
answers

UITextFieldDelegate does not hide the keyboard

Good evening, comrades I'm having a little problem with UITextFieldDelegate. I intend that when the user clicks the return key (Back) the keyboard disappears for a few moments and return the textField to write something again. But the Return...
asked by 27.03.2017 / 01:40
1
answer

What is the purpose of the NSLayoutConstraint "Aspect Ratio"?

Hello, Since I started working with AutoLayout, I did not find anything that explained how / to% As_% Aspect Ratio works. Even in the Apple documentation I did not find anything that would help to understand. Does anyone have an example to...
asked by 24.03.2017 / 11:40
1
answer

Payment to the user using Paypal and Swift

I'm trying to find a day sample code in swift required to perform a payment to the user. The PayPal development guide does not contain the syntax in swift and every attempt I made trying to translate from other languages was unsuccessful.   ...
asked by 20.06.2016 / 16:10
1
answer

I can not catch error using Try-Catch in Swift

I am making an app , which is giving me a certain error at some point, but it is only occurring on certain devices. I'm trying to catch this error with do/catch , but I'm not able to capture it. The code looks like this: do { try...
asked by 04.12.2015 / 19:51