Thread: help !!!

  1. #1
    Patent Pending GSLR's Avatar
    Join Date
    Sep 2001
    Posts
    134

    Talking help !!!

    Hi

    okey doke here we go.
    I have this directory at work that consists of about 5000 autocad drawings, the problem is that about 4 people made these drawings over a period of time and of course when you get different users u get different ways of saving files ie: I like to Capitalise the first letter, others dont care ,still its personal preferance.

    I would like to create a program that renames each drawing keeping its original nameand ext but capitalising and modifying to a set way.

    The problem is I havent a clue as to where to begin to call the actual name of the drawing into the prog so as to change it.

    At the moment I dont have any code as I dont really know where to start!

    Ok heres a little explination

    I have a folder named Drawings

    within this folder I have various drawing files
    such as

    Maj9Ls34
    maj12ls12
    maJ01LS02

    etc....

    Now I create a program and run it, it opens the folder reads in the first file name , check for capitals and lowercase and modifies accordingly. Then it continues to the next file name etc...

    When the program has finished running the folder will contain the same files like this

    Maj9ls34
    Maj12ls12
    Maj01ls02

    etc.. ( Note the caps and lowercase have been changed)

    I program in c using devc++ WIN98

    Thanx
    And To All Those Opposed, WELL !!!
    >Deleted< " Looks like a serial no."

  2. #2
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    As novacain said in this thread:
    If you use the WIN32 API you can call FindFirstFile(), FindNextFile() with the original folder, wild cards and the extension
    Please don't create duplicate threads.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

  3. #3
    Patent Pending GSLR's Avatar
    Join Date
    Sep 2001
    Posts
    134

    Unhappy !!!!

    Looking back through my threads I dont recall saying that I wanted to use a win32 api???

    Is there a way to do this using a CONSOLE application.

    Thanx for anyones help

    Q
    And To All Those Opposed, WELL !!!
    >Deleted< " Looks like a serial no."

  4. #4
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231

    Re: !!!!

    Originally posted by GSLR
    Looking back through my threads I dont recall saying that I wanted to use a win32 api???

    Is there a way to do this using a CONSOLE application.
    You said you were using Win98, therefore Win32 API would have been a good way to go.

    Have you read your compilers documentation?
    Have you got dir.h? If so, maybe look in there for function prototypes like findfirst(), findnext() etc.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

  5. #5
    Patent Pending GSLR's Avatar
    Join Date
    Sep 2001
    Posts
    134

    ok

    ok thanx ,

    Dont think that I have any compiler documentation for devC++
    Its only got a help file

    Thanx.
    And To All Those Opposed, WELL !!!
    >Deleted< " Looks like a serial no."

  6. #6
    Unleashed
    Join Date
    Sep 2001
    Posts
    1,765
    > Dont think that I have any compiler documentation for devC++
    > Its only got a help file
    STFW
    The world is waiting. I must leave you now.

  7. #7
    Registered User The Dog's Avatar
    Join Date
    May 2002
    Location
    Cape Town
    Posts
    788
    Try using the ffblk structure defined in dir.h, if you haven't found it already!

Popular pages Recent additions subscribe to a feed