Visit Jeremy's Blog.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 01-03-2009, 03:28 AM   #1
LQ Newbie
Registered: Dec 2008
Posts: 4

Rep: Reputation: 0
How to copy files after search in array from this directory to another directory!

Hi all,
After i try to find logfiles follow date/month/year. i want copy this files to another directory with name's directory is time you find(date/month/year). Could you help me write this program.
Old 01-03-2009, 05:36 AM   #2
Registered: Feb 2005
Location: agra,india
Distribution: FC2
Posts: 158

Rep: Reputation: 30
use system call cp command
Old 01-03-2009, 08:17 AM   #3
Registered: May 2007
Distribution: Debian
Posts: 754

Rep: Reputation: 59
What programming language are you using? What have you done so far? Is this your homework?
Old 01-04-2009, 07:41 PM   #4
LQ Newbie
Registered: Dec 2008
Posts: 4

Original Poster
Rep: Reputation: 0
Thanks All,
My program write by C++. and this is not my home work. this is small application which i write for my owner.
Old 01-04-2009, 07:48 PM   #5
Registered: Sep 2007
Location: Mariposa
Distribution: FreeBSD,Debian wheezy
Posts: 811

Rep: Reputation: 178Reputation: 178
So let's see the code you have so far. Tell us which part of the code doesn't seem to be working as you wish. If you're stuck on how to do something, enter each of these commands at the shell prompt:
man gettimeofday
man localtime
man sprintf
man 3 system
man cp
man sscanf
These will be directed to C programmers, but they can be used by C++ programmers as well.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you copy hidden files from one directory to another? Akhran Linux - Newbie 19 12-29-2011 04:31 AM
wxFileName +search all files in Directory bianchi Programming 1 12-28-2005 12:31 AM
copy 3 files to a directory and all subdirectories? snip128 Linux - Newbie 9 08-12-2005 10:18 PM
copy files from directory to directory without subfile ALInux Linux - General 2 06-03-2005 12:51 PM
search special files and copy in directory. abhi Linux - Newbie 2 04-10-2005 10:22 AM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 05:08 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration