Find Code:
All Words
Any of the Words
Exact Phrase
Home
:
Code
:
Forums
:
Submit
:
Mailing List
:
About
:
Contact
Code
All
VB.NET
ASP.NET
C#
VB Classic
ASP Classic
Snippets
Popular
Resources
Submit Code
Forums
Articles
Tips
Links
Books
Contest
Link to us
How to rename a file
Author:
Hamidreza khazayie
E-mail:
Click to e-mail author
Submitted:
12/21/2012
Version:
VB6
Compatibility:
VB6
Category:
File Manipulation
Views:
6519
You can call the sub to rename your file.
Declarations:
'none
Code:
Sub RenFile(Filename$, Name$) Dim d$, n%, m$ For n = Len(Filename) To 1 Step -1 d = Mid(Filename, n, 1) m = Mid(Filename, 1, n) If d = "\" Then m = m ChDir m FileCopy Filename, Name Kill Filename Exit For End If Next n End Sub
Home
|
Forums
|
Submit
|
Books
|
Mailing List
|
Advertising
|
About
|
Contact
© 2024 A1VBCode. All rights reserved.
Legal disclaimer & terms of use
Privacy statement