• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 422
  • Last Modified:

Generate large files for testing using a VB Script

Devoted Code Gurus,
I need to test an application for uploading and downloading files.  Using VB Script or any other Windows Scripting tool I need an application that will build text files as big as I specify (up to 2.5 gigabytes) and as many as I need.  Does anyone have a nice bit of code for accomplishing this?

humble regards,

Ted

0
tcalbaz
Asked:
tcalbaz
  • 3
1 Solution
 
leakim971PluritechnicianCommented:
Hello tcalbaz,

With dos : fsutil file createnew C:\incredible.hlk 2684354560

Regards.
0
 
leakim971PluritechnicianCommented:
With VBS :


Set fso = CreateObject("Scripting.FileSystemObject")
set shl = createobject("wscript.shell")
shl.run "fsutil file createnew C:\incredible.hlk 2684354560",0,true

Open in new window

0
 
tcalbazAuthor Commented:
WOW - It works perfectly!!!
Great job!
Thank you.
Ted
 
0
 
leakim971PluritechnicianCommented:
You're welcome! Thanks for the points and see you soon!
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now