A computer components & hardware forum. HardwareBanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » HardwareBanter forum » General Hardware & Peripherals » Storage & Hardrives
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Utility to write huge files instantly???



 
 
Thread Tools Display Modes
  #21  
Old January 22nd 08, 09:31 AM posted to comp.arch.storage
mike
external usenet poster
 
Posts: 121
Default Utility to write huge files instantly???

Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.


What he really want is an instant free answer to some strange problem.


And for some reason you seem to have a problem with that.

Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.

- bill

Now, boyz, let's not fight.
I found the solution in another newsgroup.
Thanks, mike

--
Return address is VALID!
  #22  
Old January 22nd 08, 11:59 AM posted to comp.arch.storage
Bill Todd
external usenet poster
 
Posts: 162
Default Utility to write huge files instantly???

mike wrote:

....

I found the solution in another newsgroup.


Great - sorry I didn't have time to research it sufficiently here.

Sharing what you found would be nice, though: I'm curious how to do
what you wanted to do, because it seemed to me to be an original
deficiency in the Win32 interface and if SetEndOfFile doesn't remedy
that I'd like to know what does (other than going down to the native API).

- bill
  #23  
Old January 22nd 08, 05:47 PM posted to comp.arch.storage
Cydrome Leader
external usenet poster
 
Posts: 113
Default Utility to write huge files instantly???

Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.


What he really want is an instant free answer to some strange problem.


And for some reason you seem to have a problem with that.


I only have a problem when the person with a problem gets crabby and
demands an answer.

Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.


If usenet is too tough for you, you might consider leaving.
  #24  
Old January 22nd 08, 07:32 PM posted to comp.arch.storage
Bill Todd
external usenet poster
 
Posts: 162
Default Utility to write huge files instantly???

Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.
What he really want is an instant free answer to some strange problem.

And for some reason you seem to have a problem with that.


I only have a problem when the person with a problem gets crabby and
demands an answer.


Polite requests for information don't qualify as 'demands' in my book.
Perhaps you're just a bit thin-skinned about having been wrong about the
existence of the answer he was looking for.


Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.


If usenet is too tough for you, you might consider leaving.


I've probably been programming computers since before you were in
diapers, sonny - and I'll likely be here long after you've gone on to
something you're more competent at doing.

- bill
  #25  
Old January 22nd 08, 08:15 PM posted to comp.arch.storage
Cydrome Leader
external usenet poster
 
Posts: 113
Default Utility to write huge files instantly???

Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.
What he really want is an instant free answer to some strange problem.
And for some reason you seem to have a problem with that.


I only have a problem when the person with a problem gets crabby and
demands an answer.


Polite requests for information don't qualify as 'demands' in my book.
Perhaps you're just a bit thin-skinned about having been wrong about the
existence of the answer he was looking for.


Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.


If usenet is too tough for you, you might consider leaving.


I've probably been programming computers since before you were in
diapers, sonny - and I'll likely be here long after you've gone on to
something you're more competent at doing.

- bill


You didn't contribute anything useful just now. Maybe you should consider
just shutting up.

That's what a wise man suggested to me.

  #26  
Old January 22nd 08, 10:54 PM posted to comp.arch.storage
Bill Todd
external usenet poster
 
Posts: 162
Default Utility to write huge files instantly???

Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.
What he really want is an instant free answer to some strange problem.
And for some reason you seem to have a problem with that.
I only have a problem when the person with a problem gets crabby and
demands an answer.

Polite requests for information don't qualify as 'demands' in my book.
Perhaps you're just a bit thin-skinned about having been wrong about the
existence of the answer he was looking for.


Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.
If usenet is too tough for you, you might consider leaving.

I've probably been programming computers since before you were in
diapers, sonny - and I'll likely be here long after you've gone on to
something you're more competent at doing.

- bill


You didn't contribute anything useful just now.


You're right: correcting the clueless is often wasted effort.

But you never know until you've tried.

- bill
  #27  
Old January 22nd 08, 11:24 PM posted to comp.arch.storage
mike
external usenet poster
 
Posts: 121
Default Utility to write huge files instantly???

Bill Todd wrote:
mike wrote:

...

I found the solution in another newsgroup.


Great - sorry I didn't have time to research it sufficiently here.


Thanks, but it's not your job to research it. I ask questions just in
case someone already knows the answer. If they have to figure it out,
they'd be doing my job.

Sharing what you found would be nice, though: I'm curious how to do
what you wanted to do, because it seemed to me to be an original
deficiency in the Win32 interface and if SetEndOfFile doesn't remedy
that I'd like to know what does (other than going down to the native API).

- bill

After playing with it for a while, I've decided that SetEndOfFile
does exactly what you'd want it to do in a NORMAL situation.
Problem is that my situation isn't anywhere near NORMAL.
Normal stuff is boring ;-)

mike

--
Return address is VALID!
  #28  
Old January 23rd 08, 01:32 AM posted to comp.arch.storage
Cydrome Leader
external usenet poster
 
Posts: 113
Default Utility to write huge files instantly???

Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.
What he really want is an instant free answer to some strange problem.
And for some reason you seem to have a problem with that.
I only have a problem when the person with a problem gets crabby and
demands an answer.
Polite requests for information don't qualify as 'demands' in my book.
Perhaps you're just a bit thin-skinned about having been wrong about the
existence of the answer he was looking for.


Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.
If usenet is too tough for you, you might consider leaving.
I've probably been programming computers since before you were in
diapers, sonny - and I'll likely be here long after you've gone on to
something you're more competent at doing.

- bill


You didn't contribute anything useful just now.


You're right: correcting the clueless is often wasted effort.

But you never know until you've tried.

- bill


So are you saying you don't learn and are prone to wasting time?
  #29  
Old January 23rd 08, 03:51 AM posted to comp.arch.storage
Bill Todd
external usenet poster
 
Posts: 162
Default Utility to write huge files instantly???

Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:
Bill Todd wrote:
Cydrome Leader wrote:

...

That's clearly not what he wants.
What he really want is an instant free answer to some strange problem.
And for some reason you seem to have a problem with that.
I only have a problem when the person with a problem gets crabby and
demands an answer.
Polite requests for information don't qualify as 'demands' in my book.
Perhaps you're just a bit thin-skinned about having been wrong about the
existence of the answer he was looking for.


Others here don't. If you have nothing useful to contribute, you might
consider just shutting up.
If usenet is too tough for you, you might consider leaving.
I've probably been programming computers since before you were in
diapers, sonny - and I'll likely be here long after you've gone on to
something you're more competent at doing.

- bill
You didn't contribute anything useful just now.

You're right: correcting the clueless is often wasted effort.

But you never know until you've tried.

- bill


So are you saying you don't learn and are prone to wasting time?


Not at all: just explaining why my earlier message only *turned out* to
be useless, rather than was so in principle (hence was worth posting on
the off-chance that you were capable of benefiting from it).

Since you asked.

- bill
  #30  
Old January 23rd 08, 08:16 AM posted to comp.arch.storage
[email protected]
external usenet poster
 
Posts: 37
Default Utility to write huge files instantly???

On Jan 19, 3:48 pm, mike wrote:
Bill Todd wrote:
Maxim S. Shatskih wrote:
I don't think he wants to take the time to zero (or otherwise write)
the actual file data. ISTR that an (undocumented?) API exists to


SetEndOfFile, it is documented.


Indeed, and that's clearly the right approach since it seems to
accomplish what's desired using a documented interface. But it was not
what I was remembering (see my other reply).


- bill


I have two problems writing code. I'm lazy.
And I have no idea what I'm doing.
I found a VB6 code example and hacked it as follows:

Private Sub Command1_Click()
Path = "x:\big1.txt"
hFile = CreateFile(Path, GENERIC_WRITE, FILE_SHARE_READ Or
FILE_SHARE_WRITE, ByVal 0&, OPEN_ALWAYS, 0, 0)
If hFile = -1 Then End
WriteFile hFile, ByVal "Very-very cool & long string", 28, BytesWritten,
ByVal 0&

SetFilePointer hFile, 900000000, 0, FILE_BEGIN
SetEndOfFile hFile
CloseHandle hFile
...

This does make a big file, but it fills the file with zeros
and takes 18 minutes to do it.
Am I using the wrong arguments?

I need to do this 16 times...I need to get rid of the 18 minutes X 16...



You probably want to use SetFileValidData(). You'll need to authorize
yourself properly first (you need to set the SE_MANAGE_VOLUME_NAME
privilege for the processes' access token with AdjustTokenPrivileges()
- and you'll need to be an administrator to do that).
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Undelete Utility for .avi files which works? news.rcn.com Storage (alternative) 6 October 18th 07 10:27 PM
Disappointing hard drive value (was: raw files are HUGE) timeOday Storage (alternative) 35 March 12th 07 12:24 AM
Looking for program/utility to slow down the write speed of a CD/DVD burner. Dan G Cdr 0 April 23rd 06 02:13 PM
Determine write date of files on dvd? Goblin28 Cdr 1 February 16th 05 01:24 PM
Utility to find duplicate files? Ian Roberts Storage (alternative) 5 October 6th 03 05:33 PM


All times are GMT +1. The time now is 02:50 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 HardwareBanter.
The comments are property of their posters.