This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var cvtFormat = NSDateFormatter() | |
| cvtFormat.dateFormat = "H:mm" | |
| var dVal = cvtFormat.dateFromString("21:30") | |
| cvtFormat.dateFormat = "h:mm a" | |
| var newString = cvtFormat.stringFromDate(dVal!) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //---------------------------------------------------------------------------------- | |
| // new class | |
| // MyMKPointAnnotation.swift | |
| // ChatMap | |
| // | |
| // Created by Don Mag on 2/15/17. | |
| // Copyright © 2017 Chris. All rights reserved. | |
| // |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import UIKit | |
| class ViewController: UIViewController { | |
| @IBOutlet var MatabiauButton: UIButton! | |
| @IBOutlet var PDFButton: UIButton! | |
| @IBOutlet var Button360: UIButton! | |
| @IBOutlet var VideoButton: UIButton! | |
| override func viewDidLoad() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Display select Contact view | |
| Did user hit Cancel? If yes, get out | |
| User selected a Contact - call custom "save()" function | |
| In save() function: | |
| Does Contact have multiple Phones? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // in cellForRowAtIndexPath | |
| // always set to Checkmark | |
| cell.accessoryType = UITableViewCellAccessoryCheckmark; | |
| // if DON'T show checkmark for this row... | |
| if (!bShowCheckmark) { | |
| UIView* myAcc = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 24, 4)]; | |
| myAcc.backgroundColor = [UIColor whiteColor]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // | |
| // ProfileViewController.swift | |
| // scratchy | |
| // | |
| // Created by Don Mag on 3/9/17. | |
| // Copyright © 2017 DonMag. All rights reserved. | |
| // | |
| import UIKit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if(foundExtra == NO) | |
| { | |
| if(movingStopped == NO) | |
| { | |
| if (!currentDrawingImage) { | |
| NSLog(@"why is it not valid here?"); | |
| } else { | |
| drawOn = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, currentDrawingImage.size.width/2, currentDrawingImage.size.height/2)]; | |
| drawOn.image = currentDrawingImage; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //: Playground - noun: a place where people can play | |
| import UIKit | |
| // peopleArray will be an Array of Dictionary objects | |
| let thePeopleArray = [ | |
| [ "firstName": "mom mobile", "phone": "242-1111"], | |
| [ "firstName": "mom work", "phone": "242-2222"], | |
| [ "firstName": "mom", "lastName": "car", "phone": "242-3333"], | |
| [ "firstName": "mom", "lastName": "home", "phone": "242-3333"], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #import <Foundation/Foundation.h> | |
| #import <CommonCrypto/CommonHMAC.h> | |
| #import "ViewController.h" | |
| @implementation ViewController | |
| - (NSData *)dataFromHexString:(NSString *)sHex { | |
| const char *chars = [sHex UTF8String]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - (void)viewDidLoad { | |
| [super viewDidLoad]; | |
| // Do any additional setup after loading the view, typically from a nib. | |
| NSArray *myArray = @[@"hello Array", @"goodbye Array"]; | |
| NSDictionary *myDictionary = @{ | |
| @"firstKey" : @"hello Dict", | |
| @"secondKey" : @"goodbye Dict" | |
| }; |