Results 1 to 5 of 5
Discuss How to show variable value with NSLog? at the iPhone Developer Exchange - Hackint0sh.org; ...
  1. #1
    Supporter Array

    Join Date
    Aug 2007
    Posts
    164
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    15

    Default How to show variable value with NSLog?

    Hi,

    somehow I can not output any variable values declared in the program
    static char *sql = "INSERT INTO book (title) VALUES(?)";
    now I want to show the sql-statement
    NSLog(@"String is %@", sql);
    but I receive
    Program received signal: “EXC_BAD_ACCESS”.
    warning: Couldn't find minimal bounds for "_sigtramp" - backtraces may be unreliable
    what am I doing wrong?



  2. #2
    Developer Array javacom's Avatar

    Join Date
    Mar 2008
    Posts
    304
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    28

    Default

    read this String Format Specifiers

    http://developer.apple.com/documenta...uid/TP40004265
    Touch Dial is an easy-to-use application for one touch dial / sms icon on the home screen for iPhone.

    This app can read the accelerometer and do phone dial or SMS dial for the same number based on the your setting for Portrait or Landscape Mode of iPhone.


  3. #3
    Supporter Array

    Join Date
    Aug 2007
    Posts
    164
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    15

    Default

    can anyone help me, please?

    I tried many of the mentioned combinations but somehow I don´t get it.
    Please help me with the right direction :-(

  4. #4
    Developer Array javacom's Avatar

    Join Date
    Mar 2008
    Posts
    304
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    28

    Default

    Code:
    static char *sql = "INSERT INTO book (title) VALUES(?)";
    NSLog(@"String is %s", sql);
    Touch Dial is an easy-to-use application for one touch dial / sms icon on the home screen for iPhone.

    This app can read the accelerometer and do phone dial or SMS dial for the same number based on the your setting for Portrait or Landscape Mode of iPhone.


  5. #5
    Professional Array

    Join Date
    Feb 2008
    Posts
    69
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    10

    Default

    NSLog(@"String is %s", sql);

    if you don't arrive to see the value of sql other thing is crashing your app before.


 

 

Similar Threads

  1. Replies: 0
    Last Post: 04-08-2009, 06:20 PM
  2. MacRumors: iTunes Store Variable Pricing to Begin April 7th?
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 03-26-2009, 04:10 PM
  3. MacNN: Nokia intros N86 8MP variable-aperture cameraphone
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 02-17-2009, 03:40 PM
  4. MacNN: Apple continues variable TV show pricing in UK
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 05-23-2008, 03:30 PM
  5. MacNN: HBO launches on iTunes with variable prices
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 05-13-2008, 03:00 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Powered by vBulletin®
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Search Engine Friendly URLs by vBSEO
(c) 2006-2012 Hackint0sh.org
All times are GMT +2. The time now is 12:14 PM.
twitter, follow us!