Jump to content

Any functions or methods to check for shortcut or .exe or .bat


Recommended Posts

Hi

Anyone have any idea how to check whether the filename extension is .lnk or .exe or .bat etc. I was looking through the functions and marcos but failed to find a suitable functions or marcos

thanks

IceMan

I made a UDF for you:

MsgBox(0,"Test.txt", _GetExt("Test.txt"))

Func _GetExt($Filename)
    $Int = StringSplit($Filename, ".")
    If IsArray($Int) Then
        Return "."&$Int[UBound($Int)-1]
    Else
        Return 0
    EndIf
EndFunc
Edited by Paulie
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...