Jump to content
Sign in to follow this  
ashvb

File rename query

Recommended Posts

Hi there

 

I've got a little vb script that copies a file to the current directory - so far so good.

 

What I'd like to do next is mimic what happens when you right-click a file in windows explorer and select 'rename' - ie I need the file name to be selected so the user can then type in a new name.

 

I know I can just rename the file with a vb command, but I want to do it this way. To illustrate:

 

icons_zpsijknremc.png

 

Is this possible?

 

Thanks!

Share this post


Link to post
Share on other sites

I'm not positive, but I don't think it's possible to do that. It seems like VBScript would be running in a different context where something like selecting the filename in Explorer wouldn't apply. Maybe you could use VBScript to interact with Explorer though, that would be the way to do that. I'm just not sure if Microsoft exposed those kinds of things. I'm sure you can get an instance of Explorer to use with VBScript, but not sure if selecting the filename is one of the things they made possible.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...