Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Karolina411
Helper V
Helper V

Importing .txt files into Power Bi using Python

Hello

I am trying to read .txt Claims files into Power Bi (june 2023 version).  Here is what it looks like: 

1) I import .txt files into Power Bi - done

2) Show the most current date - done

3) Write code to turn most recent file into a dataframe (in the column under FOLDER PATH) - I cannot seem to do it w/o getting an error message

 

Karolina411_0-1699557697012.png

 

Also--I am already reading the file into a column where the path is but my DAX code is not working:

Karolina411_1-1699557854772.png

 

Karolina411_2-1699557965014.png

 

 

1 ACCEPTED SOLUTION
Brunner_BI
Super User
Super User

I think you can only use in a python or R visual any data that you drag and drop into the visual.

Meaning you would need to put all columns in the visual first and it will automatically create a dataframe for that but it does not allow any access to anything else.

------------------------------------
Brunner BI focusing on Microsoft Power BI development and consulting
Developers of external tool "Measure Killer"
My blog

View solution in original post

1 REPLY 1
Brunner_BI
Super User
Super User

I think you can only use in a python or R visual any data that you drag and drop into the visual.

Meaning you would need to put all columns in the visual first and it will automatically create a dataframe for that but it does not allow any access to anything else.

------------------------------------
Brunner BI focusing on Microsoft Power BI development and consulting
Developers of external tool "Measure Killer"
My blog

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Top Solution Authors