Sign in to follow this  
Followers 0
Norsestar

long file names to short filenames

3 posts in this topic

anybody know the exact syntax for taking a long file / folder name and typing the short version of it?

i.e. c:\Documents and Settings <-- long name

c:\Docume~1 <-- short name

but it's not working on Windows Server 2003 OR Windows XP Pro ><

any suggestions what i might be doing wrong?

Thanks


Education: Francis Tuttle Technology Center adult full-time studentCourse of study: Network TechnologyCurrent Course: Microsoft Windows Server 2003, Enterprise EditionCompleted Courses: CompTIA A+ Hardware and Software, Windows XP Professional, Microsoft Office 2003, Desktop Support and Troubleshooting, and CompTIA Network+Remaining Courses: Linux Administration, Copper Cabling, Microsoft Windows Server 2003, Enterprise EditionAchievements: @17 years old, scored 98th percentile U.S. in Algebra 2 and Advanced Chemistry. [i.e. Ranked top 2% in the nation of High School students]

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

anybody know the exact syntax for taking a long file / folder name and typing the short version of it?

i.e. c:\Documents and Settings <-- long name

c:\Docume~1 <-- short name

but it's not working on Windows Server 2003 OR Windows XP Pro ><

any suggestions what i might be doing wrong?

Thanks

FileGetShortName() should work for ya:

MsgBox(0,"",FileGetShortName("C:\Documents and Settings\All Users\Desktop"))
Edited by Monamo

- MoChr(77)& Chr(97)& Chr(100)& Chr(101)& Chr(32)& Chr(121)& Chr(97)& Chr(32)& Chr(108)& Chr(111)& Chr(111)& Chr(107)-------I've told you 100,000 times not to exaggerate!-------Don't make me hit you with my cigarette hand...-------My scripts:Random Episode Selector, Keyboard MouseMover, CopyPath v2.1, SmartRename for XP,Window Tracer[sup]New![/sup]

Share this post


Link to post
Share on other sites

FileGetShortName() should work for ya:

MsgBox(0,"",FileGetShortName("C:\Documents and Settings\All Users\Desktop"))

awesome! it worked, thanks much


Education: Francis Tuttle Technology Center adult full-time studentCourse of study: Network TechnologyCurrent Course: Microsoft Windows Server 2003, Enterprise EditionCompleted Courses: CompTIA A+ Hardware and Software, Windows XP Professional, Microsoft Office 2003, Desktop Support and Troubleshooting, and CompTIA Network+Remaining Courses: Linux Administration, Copper Cabling, Microsoft Windows Server 2003, Enterprise EditionAchievements: @17 years old, scored 98th percentile U.S. in Algebra 2 and Advanced Chemistry. [i.e. Ranked top 2% in the nation of High School students]

Share this post


Link to post
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
Sign in to follow this  
Followers 0