LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to delete desktop shortcuts

Hello all,

 

Can anyone tell me how to delete desktop shortcuts with LabVIEW.

 

I tried with delete.vi & through cmd but its deleting actual source file.

Just I want to remove corresponding shortcut from desktop (It should not delete actual source file).

 

Please help me if anyone have idea.

Munna
0 Kudos
Message 1 of 7
(3,660 Views)

Show how you are doing it.  Are you trying to delete the file with an extension that ends in ".lnk"?

Message 2 of 7
(3,645 Views)

Dear RavensFan,

 

Thanks for quick response.

 

Sorry, I'm deleting file with an extension that ends in ".exe" (instead of  ".lnk").

Now it's working well.

Munna
0 Kudos
Message 3 of 7
(3,640 Views)

Hello All,

 

As per attached snippet,

I can delete shortcuts from given input folder (if I'm running this VI alone). But when I’m making this VI as subvi, shortcuts are deleting but still its showing in the mentioned folder. When I’m refreshing that folder, its disappearing.

 

I don’t know why it’s happening like this. Please help me if anyone have idea.

 

Delete Shortcut.png

Munna
0 Kudos
Message 4 of 7
(3,613 Views)

@Munna232 wrote:

I can delete shortcuts from given input folder (if I'm running this VI alone). But when I’m making this VI as subvi, shortcuts are deleting but still its showing in the mentioned folder. When I’m refreshing that folder, its disappearing.


That sounds like normal Windows behavior to me.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 5 of 7
(3,588 Views)

Hello Crossrulz,

 

Is there any idea for this?

 

I think after delete, we need to refresh that folder dynamically.

Munna
0 Kudos
Message 6 of 7
(3,560 Views)

Perhaps this will give you some hints on how to get the Windows Explorer to auto-refresh:

https://social.technet.microsoft.com/Forums/windows/en-US/c8b1f896-bbb7-43b8-be8e-5d28916268e0/windo...

 

0 Kudos
Message 7 of 7
(3,537 Views)