Page 8 of 9 FirstFirst ... 6789 LastLast
Results 71 to 80 of 86

Thread: Copy Paste based on comparisons calculations in 2 XL files, 1 might be .csv file .Opened in XL=Fail/Chaos

  1. #71
    Senior Member
    Join Date
    Jul 2019
    Posts
    382
    Rep Power
    0
    Either of these 2 conditions are to result in macro will copy value in column I of sample1.xls to field 2(column B) of text file Sample2.csv on a new line:
    Condition 1) Only If column K of sample1.xls is greater than Column D of sample1.xls & Column H of sample1.xls is Greater than column K of sample1.xls then Match Column I of sample1.xls with second field values (column B) of sample2.csv & if it is there then do nothing & if it is not present then paste the column I data of sample1.xls to append second field values (column B) of sample2.csv

    Condition 2) Only If column K of sample1.xls is lower than Column D of sample1.xls & Column H of sample1.xls is lower than column K of sample1.xls then Match Column I of sample1.xls with second field values (column B) of sample2.csv & if it is there then do nothing & if it is not present then paste the column I data of sample1.xls to append second field values (column B) of sample2.csv


    I need the macro for the same Doc Sir

  2. #72
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,385
    Rep Power
    10

    Why are you posting the question again

    OK, maybe you did wrote it a bit better. .... good

    But the answer is the same..
    Second part of this post for explanation : https://excelfox.com/forum/showthrea...ll=1#post13482
    Macro https://excelfox.com/forum/showthrea...ll=1#post13478

    So if you are not getting what you want, you must try very carefully to explain what the problem is, and supply the corrrect files and tell me what is the error etc....etc..


    Maybe, now you need to go back here :
    https://excelfox.com/forum/showthrea...ll=1#post13530
    and start again but upload the correct text file!!!

    Your problem is like almost always, very very simple to answer...
    But you are totally incapable of communicating in English, so cannot ask the question or explain the problem.
    We all waste out time because you understand almost no English, and cannot communicate in English
    Last edited by DocAElstein; 06-09-2020 at 02:11 AM.
    ….If you are my competitor, I will try all I can to beat you. But if I do, I will not belittle you. I will Salute you, because without you, I am nothing.
    If you are my enemy, we will try to kick the fucking shit out of you…..
    Winston Churchill, 1939
    Save your Forum..._
    _...KILL A MODERATOR!!

  3. #73
    Senior Member
    Join Date
    Jul 2019
    Posts
    382
    Rep Power
    0
    Download file link
    https://drive.google.com/file/d/1cpu...ew?usp=sharing
    https://drive.google.com/file/d/1MBR...ew?usp=sharing

    Explanation of the problem:
    Either of these 2 conditions are to result in macro will copy value in column I of sample1.xls to field 2(column B) of text file Sample2.csv on a new line:
    Condition 1) Only If column K of sample1.xls is greater than Column D of sample1.xls & Column H of sample1.xls is Greater than column K of sample1.xls then Match Column I of sample1.xls with second field values (column B) of sample2.csv & if it is there then do nothing & if it is not present then paste the column I data of sample1.xls to append second field values (column B) of sample2.csv

    Condition 2) Only If column K of sample1.xls is lower than Column D of sample1.xls & Column H of sample1.xls is lower than column K of sample1.xls then Match Column I of sample1.xls with second field values (column B) of sample2.csv & if it is there then do nothing & if it is not present then paste the column I data of sample1.xls to append second field values (column B) of sample2.csv


    After runing the macro given by you causing Error

    Error details- "Input past end of file"
    Highlighted line in the module:
    Code:
    Line Input #FileNum, TextFileLineIn '  next line in text file

  4. #74
    Senior Member
    Join Date
    Jul 2019
    Posts
    382
    Rep Power
    0
    We will not play with .csv files
    Doc Sir do not work on this problem
    changing the .csv files with .xlsx
    My system also accepts Notepads files
    so what i will do is i will prepare the data in .xlsx file and then convert all that data from.xlsx to notepad
    Plz leave this problem ignore it
    I dont want macro for the same
    Thnx Alot For ur Great Help

  5. #75
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,385
    Rep Power
    10
    This is the file that you uploaded : https://imgur.com/Ooc7WBU
    ( https://drive.google.com/file/d/1MBR...ew?usp=sharing )
    It is the same text file that you gave in post#1
    https://excelfox.com/forum/showthrea...ll=1#post13475


    If I run my macro given to you, using that complete file , then I do not get that error!

    Are you sure you get the error when running the macro with that file?

    If not…
    I need the text file that you are using when you get that error


    ( I think we are back now to where we started yesterday..... )
    ….If you are my competitor, I will try all I can to beat you. But if I do, I will not belittle you. I will Salute you, because without you, I am nothing.
    If you are my enemy, we will try to kick the fucking shit out of you…..
    Winston Churchill, 1939
    Save your Forum..._
    _...KILL A MODERATOR!!

  6. #76
    Senior Member
    Join Date
    Jul 2019
    Posts
    382
    Rep Power
    0
    Yes but this was the last misunderstanding happened
    I converted all .csv file to .xlsx file
    Bcoz playing with .csv file are difficult & we should work smartly, why we should work Hard If the problem can be solved Smartly & easily
    My system Accepts notepad file also, So I dont need .csv files now

  7. #77
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,385
    Rep Power
    10
    Quote Originally Posted by fixer View Post
    ....
    My system also accepts Notepads files... then convert all that data from.xlsx to notepad
    .....
    You are talking rubbish again
    There are no such things as notepad files. I told you this hundreds of times
    ….If you are my competitor, I will try all I can to beat you. But if I do, I will not belittle you. I will Salute you, because without you, I am nothing.
    If you are my enemy, we will try to kick the fucking shit out of you…..
    Winston Churchill, 1939
    Save your Forum..._
    _...KILL A MODERATOR!!

  8. #78
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,385
    Rep Power
    10
    I think your problem is very very simple

    I just need the text file, the sample2.csv, that gives you that error
    ….If you are my competitor, I will try all I can to beat you. But if I do, I will not belittle you. I will Salute you, because without you, I am nothing.
    If you are my enemy, we will try to kick the fucking shit out of you…..
    Winston Churchill, 1939
    Save your Forum..._
    _...KILL A MODERATOR!!

  9. #79
    Senior Member
    Join Date
    Jul 2019
    Posts
    382
    Rep Power
    0
    Doc Sir No probelm
    I will share it to u
    But if i continue with.csv file Now and in future ask question then again it will create trouble
    So its better to stay away from .csv file & macro related to .csv files
    plz see my new 2 question & u will understand what i have done & u will like it
    I hope So

  10. #80
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,385
    Rep Power
    10
    OK
    But I would like to solve this problem because i have already done so much work on it

    How about this...

    Give me 2 text files

    sample2Before.csv
    - This will be the file that gives you the error

    sample2After.csv
    - This is excactly the file that you want after.

    or just give me the one file that gives the error
    Last edited by DocAElstein; 06-09-2020 at 12:10 PM.
    ….If you are my competitor, I will try all I can to beat you. But if I do, I will not belittle you. I will Salute you, because without you, I am nothing.
    If you are my enemy, we will try to kick the fucking shit out of you…..
    Winston Churchill, 1939
    Save your Forum..._
    _...KILL A MODERATOR!!

Similar Threads

  1. Replies: 26
    Last Post: 09-26-2020, 05:56 PM
  2. Copy paste data based on criteria
    By analyst in forum Excel Help
    Replies: 7
    Last Post: 01-13-2014, 12:46 PM
  3. Replies: 8
    Last Post: 10-31-2013, 12:38 AM
  4. Replies: 2
    Last Post: 09-18-2013, 12:30 AM

Tags for this Thread

Posting Permissions

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