Need program searches numbers inside a txt and perfroms an opperation

Program that will search specific numbers from inside a txt,cut them,and ask me to put the name of the folder to put them in :


So the whole idea is about a program that will search inside the txt i will give whatever number starts with _ (Example : _10165,_09957 ),and with the results it will search the directory wich i give.Example C:Id Boxes and tell me wich of the numbers that searched from the txt are not found in this folder as archives (other .txts).Then cut those that found and ask me to create a folder with them.

I have attached a copy of how exactly the txt looks.In this txt there are the numbers that the program will "see" and perfrom the opperation i said before.
Unless there is a program out there in the internet space wich already does it??

For further details please,question me!
Any help,comments,ideas would be much appreciated



Comments

  • algorithm
    -opening a file
    -searching for a expression
    -if found place in destination folder


    you should attach the file and some use cases.
    I am in relearning process, sorry if i make a mistake
  • First of all,thanks for answering my question.

    Well on the file :CId Boxes image that there are like 10 thousand files.Their names are like this : "IM1905091047_1_03521.txt"
    And yes an output folder were the .txts will be moved.It would be nice if the program would create a folder,so i type the name,and move them in.
    As you notice the whole scene is about to organise those 10 thousand .txts and put them into folders.

    About the search in the C:Id Boxes now.The "IM1905091047" except the IM,is day,month,year,time and minutes wich the txt was created,and it's named that way.Here is the reason why the program much search with the "_" in front:

    Let's say in this case we want to search for 1047,there is this .txt right here "IM1905091047_1_03521" and this txt right here "IM1905091047_1_10231".
    The search will bring both the archives,and we do not want that smiley

    That's why there is the "_" there.The program will search for the _1047.Exaclty as it's reffered in the attached .txt i sent you.

    By the way there is a great chance to be dublicated files there,so a report would be nice


  • You actually need a program to do this.
    If it is for you personal use it might be easier to use your dos command prompt.

    mkdir
    mv .txt // =*str.txt or *str*.txt or str.txt

    I don't know how to do the dir and mv command in windows C++ so anyone could elaborate.

    It not a hard program I just don't have the dir and mv knowledge in Windows
    I am in relearning process, sorry if i make a mistake
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories