Reading a csv file. Can not find file

I need to read data in a CSV file to control my models animation.

(see below) This seems to be the most common answer but it does not work.
I get a file or directory not found error.
My file (Program.txt is in the same folder as the blender model)

import bpy
import csv

line = 1
column = 2

with open(“Program.txt”,“r”) as file:
mycsv = csv.reader(file)
mycsv = list(mycsv)
text = mycsv[line][column]
print(text)
rotate=int(text)

Am I posting in the wrong forum?

This is the right forum, it’s just not very active.

Did you try using the full path of the file? Something like:

with open(“Directory/File/Located/In/Program.txt”,“r”) as file:

e.g. (assuming Windows is the OS):

# note: use '/' instead of '\'
with open("C:/Users/Username/Documents/Program.txt","r") as file:

I think you can see which directory Blender is currently running in using Python’s “os” library:

import os


# print current working directory
print( "Working Directory: ",  os.getcwd() )

import os

with open(bpy.path.abspath("//Program.txt"), "r") as file:

[\code]

Thanks but that did not work.

See below, this does work.

from pathlib import Path
p = Path(‘C:/’)/‘Users’/‘Owner’/‘Desktop’/‘Blender’/‘Probot 2/Program.txt’
print(str§)