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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Ramh84
Frequent Visitor

Automatic Unwrapping to any wrapped cells in appended CSV files using Folders as the data source

Dears,

 

How to ensure that I have no wrapped cells in CSV files?

 

Lately, I have found that some of the source files (CSV files) have some wrapped cells in various locations in the files.

 

I thought of using TRIM function to trim all [ABC] formatted columns, but this didn't work at all when exporting the processed CSV data as atable from BI file.

 

To solve this manually, I had to follow this excel manual solution https://techcommunity.microsoft.com/t5/excel/need-help-removing-wrap-text-from-3-cells-not-as-easy-a... . And it did work!

However, I am aimng to put above mentioned barrier in place when using Power BI to autmatically detect such an issue and correct it on-th-go.

That is why I am wondering if it is possible to mimic above solution to automatically take into account such unwanted wrapped cells that can be found as part of CSV files?


Appreciate if you have a suggestion for above issue. 

1 ACCEPTED SOLUTION

In your sample file, the word-wrap is caused by a Line Feed in the LT_Summary column. All you need to do is remove that.

 

Insert or Add a step using the Replace Values option:

 

ronrsnfld_0-1693823183588.png

 

and that takes care of it on your sample file.

 

If there are other columns with word wrap, you can select them also at the same step.

View solution in original post

4 REPLIES 4
Ramh84
Frequent Visitor

Thanks so much for your great support, ronrsnfld!

This is exactly what I wanted to acheive.

 

Really appreciated!

ronrsnfld
Super User
Super User

Please provide a text sample (or link to a csv file) that demonstrates the problem and a screenshot that shows your expected result. It should be fairly simple in Power Query.

Thanks for your reply.

Please find a link to the sample file, as requested.

 

Below screenshot demonstrates the isue I am facing when some randome cells in the CSV file might be wrapped.

I am looking for automating the decection and fixing such wrapped cells the moment I load them in the BI file.

Much appreciated,

 

Ramh84_0-1693788736407.png

 

In your sample file, the word-wrap is caused by a Line Feed in the LT_Summary column. All you need to do is remove that.

 

Insert or Add a step using the Replace Values option:

 

ronrsnfld_0-1693823183588.png

 

and that takes care of it on your sample file.

 

If there are other columns with word wrap, you can select them also at the same step.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.