Results 1 to 10 of 10

Thread: long to char ***Resolved

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member Wak's Avatar
    Join Date
    Nov 2000
    Location
    Brisbane, Queensland
    Posts
    298

    long to char ***Resolved

    I know this has probably been asked a thousand times, and I've searched all through the forums and I'm still getting errors..

    Code:
    char Space[255];
    long lNumber;
    
    lNumber = 223538;
    I've tried
    Code:
    sprintf(space, "%i", (int)lNumber);
    
    itoa((int)lNumber, space, 10)
    
    *(long*)space=lNumber;
    And from what I can work out, they either do nothing, or are converting the number into actual ascii characters. I simply want
    Space = "232538";

    as such.

    Thanx
    Last edited by Wak; Nov 2nd, 2002 at 08:47 PM.
    Visual Basic 6.0 Enterprise
    Visual C++ 6.0 Professional

    Wak

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width