Common Swift collection casting or type conversion
Tech-Today

Common Swift collection casting or type conversion


Collection of Common Swift Casting  or Type Conversion

String to Double
var a  = "1.5"
var b  = (a as NSString).doubleValue

Double to String
var a : Double = 1.5
var b  = String(format:"%f", a)

Double to Int
var a : Double = 1.5
var b  = Double(a)

String to Float
var a  = "1.5"
var b  = (a as NSString).floatValue

String to Float
var a  = "1.5"
var b  = (a as NSString).intValue






- Useful Article Links In Studying Swift
1.) For studying the basic of swift :      file:///Users/czetsuya/Downloads/404_advanced_swift.pdf-,%20attachment 2.) Useful for studying "Case Classes"      http://masteringios.com/blog/2014/06/26/hello-swift/2/ 3.) “Building...

- Dns That You Could Choose From In The Philippines
Below are the DNS I'm using in the Philippines. The last is specifically for Globe network. OpenDNS - fast but restrictive    208.67.222.222    208.67.220.220 Cisco - ok for me    64.102.255.44    128.107.241.185...

- Elmah Not Logging, Elmah.axd Page Is Always Null When Using Sqlerrorlog
First make sure that you're web.config file is setup properly and that you have defined elmah to handle the error in each controller. You can do that easily in c# mvc3 by using nuget and downloading elmah, elmah.corelibrary and elmah.contrib.mvc....

- How To Access Asp:textbox With Runat=server Attribute In Javascript
For example you have a textbox which has a default value, and you want to clear that value when the user click on the textbox: <asp:TextBox ID="txtBox" runat="server" onclick="clear()" Text="Enter Keyword" /> <script type="text/javascript">...

- Create An Image Slide Show In Iphone Using Xcode
Here's how you can create image slide show from xcode - iphone Requirement:  -3 png images. 1.) Create a new View-based application project. Name it AnimationDemo. 2.) Once the new project is created. Add the 3 png images to the Resources folder....



Tech-Today








.