Hey @StefT
please try the following action and settings to get all items from your SharePoint library that has a '#' in the Filename:

substringof('#',FileLeafRef)
If you would use the Name column, you would see an error, because eventhough the column exists, you cannot use it within the filter. The "FileLeafRef" will give you the 'filename.documenttype', this column we can also filter. Using the substring we checking if there is a '#' within the filename.
Next you would need to run through every item using an "apply to each" and update the FileLeafRef using HTTP:

Site Address: <YourSiteAddress>
Method: POST
URI: _api/web/lists/getbytitle('Documents')/items(@{items('Apply_to_each')?['ID']})
Headers:
Accept: Application/json;odata=verbose
Content-Type: Application/json;odata=verbose
IF-MATCH: *
X-HTTP-Method: MERGE
Body:
{'__metadata':{'type':'SP.Data.<Your Library Internal name (Check URL)>Item'},'FileLeafRef':'@{replace(items('Apply_to_each')?['{FilenameWithExtension}'],'#','_')}'}
The replace expression looks like this:
replace(items('Apply_to_each')?['{FilenameWithExtension}'],'#','_')
Afterwards your Filenames should have been changed.
Does this help you? Otherwise please give me some more information.
Best regards
Marvin
If you like this post, give a Thumbs up. If it solved your request, Mark it as a Solution to enable other users to find it.
Blog: Cloudkumpel