Convert path to URL?

pjbw

New member
Local time
3:10 AM
Messages
8
I am looking for quickie app into which I can paste a Windows 7 file path and which converts it to a URL.
Very simple: prefixes the path with file:/// and then changes all the \'s to /'s.
(Easy to edit the paths but life's too short).
Are there any suggestions?
 

My Computer

OS
Windows 7 Professional 32 bit
It sounds like you currently put a path to a file into the OS clipboard (perhaps using shift-right-click from within Windows Explorer) and then paste/modify that info into the address field of a browser - correct?

Does the path that you start with contain a mapped drive letter or is it a UNC connection? Do you need the app that you are looking for to handle both local/mapped drive paths and UNC paths?

Are there quotation marks around the original path?

Most browsers already convert \ to / and they will handle a mapped local, mapped and UNC paths as is.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Employer provided Dell Latitude
OS
W7 Pro SP1 64bit
CPU
i7
Memory
8GB
Graphics Card(s)
Intel HD Graphics
Hard Drives
crappy SSD
Antivirus
Employer mandated Symantec Endpoint Protection
Browser
Pale Moon 64bit, IE11 64bit & Chrome 64bit
It sounds like you currently put a path to a file into the OS clipboard (perhaps using shift-right-click from within Windows Explorer) and then paste/modify that info into the address field of a browser - correct?

Does the path that you start with contain a mapped drive letter or is it a UNC connection? Do you need the app that you are looking for to handle both local/mapped drive paths and UNC paths?

Are there quotation marks around the original path?

Most browsers already convert \ to / and they will handle a mapped local, mapped and UNC paths as is.

I use Thunderbird email client and can Save an email as .eml.
Then in PowerDesk file manager I select the file and Edit, Copy Path as Text.
I then paste this text path into the Notes pane of 'Handy Address Book' against the relevant contact.
HAB doesn't know about Windows paths but if in HAB I prefix the path with 'file:///' and change the back-slashes to make it a URL it goes blue and I can click on it to open the .eml file in my default Opera browser.
From there I can paste the relevant text back into HAB under the relevant URL.
This is very readable and useful.

However I was brought up with Unix and my file paths are often very long; no Libraries, no My Documents, etc. and so editing the paths is tedious.
There must a way to automate this. I do like HAB for managing contacts; maybe something completely different is called for...
 

My Computer

OS
Windows 7 Professional 32 bit
A few lines of scripting via AutoIt should do what you want:

Code:
$var = StringReplace(ClipGet(), "\", "/")
$var = StringReplace($var, "c:", "file://")
ClipPut($var)

You can edit the "c:" part as needed.

You can run that script via an OS shortcut key...
(assign it something like Ctrl-Alt-c for convert)
...or you can add code that lets it run all of the time - converting the info in the OS clipboard when you press some key or key combo.

Personally, I would leave the script as a text file and run it like that. If you would rather compile it, see the info just above and below the last video in this post.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Employer provided Dell Latitude
OS
W7 Pro SP1 64bit
CPU
i7
Memory
8GB
Graphics Card(s)
Intel HD Graphics
Hard Drives
crappy SSD
Antivirus
Employer mandated Symantec Endpoint Protection
Browser
Pale Moon 64bit, IE11 64bit & Chrome 64bit
Apologies for late acknowledgement.
I am working through AutoIt and it does look as if it will do the job.
 

My Computer

OS
Windows 7 Professional 32 bit
Hello,

this task can be solved a lot easier with "Copy UNC Path". That's indeed a great tool.

Kind regards,

DAC324
 

My Computer

Computer type
PC/Desktop
OS
Windows 7 Ultimate 64 bit

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Employer provided Dell Latitude
OS
W7 Pro SP1 64bit
CPU
i7
Memory
8GB
Graphics Card(s)
Intel HD Graphics
Hard Drives
crappy SSD
Antivirus
Employer mandated Symantec Endpoint Protection
Browser
Pale Moon 64bit, IE11 64bit & Chrome 64bit
Back
Top