Python Forum
Need to compare the Excel file name with a directory text file.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need to compare the Excel file name with a directory text file.
#1
Thumbs Up 
*)Read the excel file and iterate through rows. The first column has "File Name"
*)Read the file name and check the PDF file with the same name available in the folder
*)If the file is present then write the result as "File found" in .txt
*)Also copy the respective links, column B and column C values and write in .txt file
*)If the file is not present then write the result as "File not found" in .txt file

I want to compare and perform the task. Appreciate it if you share any thoughts.

Attached Files

Thumbnail(s)
   
Reply
#2
What have you tried so far? Please show code working or not, and specific question about where it fails.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  open a text file using list() Pedroski55 2 115 Feb-25-2026, 06:57 PM
Last Post: noisefloor
  If I open a file write or append, is the file loaded into RAM? Pedroski55 11 1,118 Jan-14-2026, 07:49 AM
Last Post: Pedroski55
  How to Randomly Print a Quote From a Text File When User Types a Command on Main Menu BillKochman 13 7,273 Dec-16-2025, 05:29 PM
Last Post: zodazy
Question [SOLVED] Linefeed when writing "f" strings to text file? Winfried 5 858 Nov-04-2025, 11:51 AM
Last Post: buran
  subprocess FileNotFoundError: [Errno 2] No such file or directory: Pedroski55 11 2,555 Aug-07-2025, 02:10 AM
Last Post: Pedroski55
  How can I write formatted (i.e. bold, italic, change font size, etc.) text to a file? JohnJSal 13 36,670 May-20-2025, 12:26 PM
Last Post: hanmen9527
  How to write variable in a python file then import it in another python file? tatahuft 4 2,253 Jan-01-2025, 12:18 AM
Last Post: Skaperen
  Problems writing a large text file in python Vilius 4 2,033 Dec-21-2024, 09:20 AM
Last Post: Pedroski55
  Get an FFMpeg pass to subprocess.PIPE to treat list as text file? haihal 2 2,461 Nov-21-2024, 11:48 PM
Last Post: haihal
  JSON File - extract only the data in a nested array for CSV file shwfgd 2 2,250 Aug-26-2024, 10:14 PM
Last Post: shwfgd

Forum Jump:

User Panel Messages

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