Python Forum
Replace lines from one .txt file to another
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Replace lines from one .txt file to another
#3
(Jun-21-2017, 10:45 PM)Ofnuts Wrote: If you want to take some line in file1 and write them at the end of file2, it is more like:

Yes i want write them file2, but not the end always, some times need write it line 3 or line 10 etc... How i can adjust this which(number) line i'll write?
Reply


Messages In This Thread
RE: Replace lines from one .txt file to another - by Tumppi - Jun-22-2017, 03:58 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Replace a text/word in docx file using Python Devan 4 4,113 Oct-17-2023, 06:03 PM
Last Post: Devan
  Need to replace a string with a file (HTML file) tester_V 1 854 Aug-30-2023, 03:42 AM
Last Post: Larz60+
  Replace columns indexes reading a XSLX file Larry1888 2 1,057 Nov-18-2022, 10:16 PM
Last Post: Pedroski55
  Delete multiple lines from txt file Lky 6 2,440 Jul-10-2022, 12:09 PM
Last Post: jefsummers
  How to do a mass replace within a CSV file? cubangt 9 5,651 May-09-2022, 06:52 PM
Last Post: snippsat
  I get an FileNotFouerror while try to open(file,"rt"). My goal is to replace str decoded 1 1,470 May-06-2022, 01:44 PM
Last Post: Larz60+
  failing to print not matched lines from second file tester_V 14 6,354 Apr-05-2022, 11:56 AM
Last Post: codinglearner
  Extracting Specific Lines from text file based on content. jokerfmj 8 3,218 Mar-28-2022, 03:38 PM
Last Post: snippsat
  Importing a function from another file runs the old lines also dedesssse 6 2,696 Jul-06-2021, 07:04 PM
Last Post: deanhystad
  [Solved] Trying to read specific lines from a file Laplace12 7 3,675 Jun-21-2021, 11:15 AM
Last Post: Laplace12

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020