SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Jul 2000
    Location
    Lawrence, NY
    Posts
    20
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Need somehelp here, any input is appreciated:

    Let's say I want to do the Unix command: cd dir
    How would I do that in C++ ??

    I can't just say cd dir, since C++ has no clue what that means. Does anyone have any ideas on this?


    Thanks

  2. #2
    Your Lord and Master, Foamy gold trophy Hierophant's Avatar
    Join Date
    Aug 1999
    Location
    Lancaster, Ca. USA
    Posts
    12,305
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Might want to look up documentation for the system() function that came with your compiler.

    However, C++ has functions for accessing the disk and files built in...

    to change the directory you would use the chdir() function. There are many others. Most C++ books have a chapeter dedicated to disk and file access in them.
    Wayne Luke
    ------------


  3. #3
    SitePoint Evangelist
    Join Date
    May 2000
    Location
    Canada
    Posts
    533
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the wonderful world of C .. i just learned some Java (even tho i personally think its pathetic), but hey, i got into object oriented programming, which seems like its really useful, as far as applications go, still useless to me in my php scripts

    ok, so this was a rant! .. haha, gimme a break wayne

    --------------------
    myPHPhost.com - somebody say php?


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
  •