Discussion in 'other software & services' started by Kas, Apr 10, 2009.
Thanks. I have used this application in the past and will try again.
I'm using XP and Pagefile Usage Monitor is working like a charm. Maybe a problem in the ruinebabine XP system.
To adjust pagefile size this utility is excellent. Better than the ram'tweaks (*1,5 min/*3.0 max).
In Win98 days, the Page File was referred to as the Swap File since the theory was that when your available Memory (RAM) was used up, Windows "swapped" data to disk (Page File). If you had enough memory, nothing was ever swapped to disk, except what Windows puts there for its own use. So, you could keep the Page File small.
Along comes Win2K and 1.5x the available RAM is recommended. (I don't recall that in Win9x). Well, that is a lot of wasted space, since I want my C partition to be small for just the OS and related stuff. But maybe the NT5 OS works differently with Memory than Win9x. Time do do some reading:
Configuring Operating System Settings
So, the principle is the same in Win2K, just a different approach.
What is the Page File for anyway?
I found that my programs on the Win2K system weren't using any more Memory than on Win9x. (The real improvement was how threads are managed which eliminated the problem of depleted resources - User and GDI).
I found that the Page File was always small, probably from normal Windows stuff - nothing swapped from depleted available RAM. I concluded, no necessity for a large Page File. Also, I never noticed any difference with adding a Page File on my 2nd internal HD, so I use just one.
I believe that ruinebabine stated that the program would not start and that the error occurred before the Form was displayd.
This can happen ONLY if the LOAD Event, i.e., the code that creates the Form fails.
All that the Load event does is:
1. check whether the OS is Win 2000 or later. This is done using the GetVersionEx API function. It's not OS dependent.
2. Checks whether wbemdisp.tlp is installed. So, on ruinebabine's system, wbemdisp.tlp was installed, but the services had not been started. I'll, eventually, look into whether I can check those services in the load event.
3. Checks whether another instance of the program is running. No point in allowing more than 1 copy of the program to run at the same time.
4. Then the controls on the Form are given their values.
5. Then the log file is opened.
6. Finally, the Load event displays the Form.
Prior to this point, the only things that could go wrong are:
a. Improperly installed WMI
b. Improperly installed VB 6 or VB 6 runtimes.
c. Issue with XP or SP3. In another Forum, I saw threads just today describing a problem with pre-release SP3 for VB.
Given that the program works in Win 2000 and Vista, and others have had success with XP, I am puzzled.
That's why I wrote the program.
There was a noticeable improvemen in system performance after I reallocated the pagefils.
I have 10 logical drives on 3 SCSI hard drives.
There are 4 OS.
1 on C on drive 1.
2 on F and G on drive 2.
1 on J (my main OS) on drive 3.
So I set a small (64MB) fixed-length file on C, and a larger variable-length page file on G, min 128, max 1088. Used to have a min of 64MB oh G, as well, but Acronis True Image almost required at least 128MB, so I yelled Uncle!
I rarely boot to the OS on C, F, and G
Ooops, forgot to mention:
d. SP 6 for VB 6 or the VB 6 runtimes is not installed. SP6 was released more than 5 years ago.
All OS, from the 1st computer and al future computers have always swapped stuff in/out of memory.
Heck the first computer I seriously programmed (IBM 1620) had only 20000 characters of memory.
It was quite a leap when I started programming an IBM 36/30 with a whopping 64K of bytes, WOW!
IBM made a big deal about swapping/paging when the IBM 370 was announced. Folkes got all excited.
Over the years programming techniques have gotten better, but the underlying mapping of physical memory to page/swap files is still with us.
Also, memory and disk drives are much less expensive.
The runtimes, from the link that you provided.
Xp Pro sp2, as already stated I think.
Yes, only the run-time error 9 message, but it also produces (but doesn't display) an empty "PageFileLog.txt" file in its folder at each new try to run.
LOL! I was not trying to be your nutfeeding pusher in any ways, Howard. Simply would like to pinpoint why my pc's settings are nut allowing your prog to run as it should. And, reading here that PageFileUsageMonitor is making good on other XP's systems, we might safely assume that the problem is from my side. I will continue to try to make it work and report back here of any progress.
Good. See below
In the lead posting, you had stated XP Home and SP 3.
THelast thing that the Load event does is open the file, then get the pagefile info to display when te Form is displayed.
I've stepped thru that code in both Win 2000 (1 and 2 page files) and Vista ( page file). The code is executing correctly, and others are using the prog succcessfilly, so either there is a problem on your system or my code has one of the most suble bugs ever encountered.
The code is really very simple, and I have not found an error, but that does not mean there isn't one.
I'll be competing with the local squirrels for nuts.
All OKs, but...
...t'was Kas' post.
Sorry, this thread has made me bleary eyed.
I was thinking last night that, if somehow I do have a subscript issue in the code, or an issue related to subscripts caused by your installation, I may try to rewrite the code to use less subscripts. Code would likely be less efficient, but that might eliminate the problem you see.
Although, if my code has a subscript issue, then others should be seeing the same problem.
Ooops, I was just going thru some mail folder, and found a message that I received dated 3 Sep 2008. I missed reading the message.
He reported a problem running the program when there was NO page file.
I cannot seem to find a way to tell Win 2000 to manage pagefiles itself.
If I delete the pagefiles, Windows 2000 creates a temporary page file that the program detects.
I think that I know how to tell Vista to manage the pagefile.
I'll test there later today.
I forgot to mention that I do not know what verson of the program he was using.
vista is set up to handle the pagefile itself and version 188.8.131.52 of the prog handles that.
Why I created version 184.108.40.206
A similar message was posted in this forum.
Regarding the “Runtime error ‘9’: Subscript out of range” message when using Howard’s Pagefile Usage Monitor:
I’m running WinXP, SP3, and have two hard drives, one of which is mounted in a removable tray. I have two pagefiles, one on each HD. I keep a small pagefile on the permanent HD, as Windows will create a much larger one if there isn’t one already there. I have a larger one on the removable HD, as that seems to help photo processing.
If I start my computer without the removable drive, I will get the “Runtime error ‘9’: Subscript out of range” error message. If both drives are mounted, Howard’s program works great. So, just something to check; if Windows boots up looking for a pagefile that it doesn’t find, perhaps this causes the error. This is just from observation, I know little to nothing about the mechanics of this stuff.
THat makes sense.
The OS knows that there's another page file, so if the file cannot be found, the OS gives a less than useful message.
All my prog can do is ask WMI how many page files exist.
That info likely comes from the registry, without checking for physical existence.
I've rewritten my code to reduce the number of subscripts.
Should not make any difference, but, heck, we are dealing with Windows!
The new version is temporarily at Temporary Version of PageFileUsageMonitor
This version produced no errors. That was quick.
In addition to reducing subscripting, I added code that should catch certain types of errors.
It seems that Win32_PageFileUsage and Win32_pageFileSetting operate differently in return info on the pagefiles. Note that Win32_PageFileUsage as an additional property in Win XP, not in Win 2000.
In a few minutes, I'll replace version 220.127.116.11 with an updated version 18.104.22.168.
Temporary version has been deleted.
A new version has been placed at PageFileUsageMonitor.
Also modified the document to state that the WMI service must be Started with a Startup Type of Automatic.
I simply unzipped it over 22.214.171.124 and guess what...
Good job, Howard. The bad news: no more nuts from me,
Thanx, I'll sleep better tonight.
I intend to change the program to test whether WMI is installed.
I'll post here to let folkes know when that is done.
Just released version 126.96.36.199.
It should detect whether the WinMgt service is installed.
If WinMgt is installed, the program should automatically start WMI even if you have WinMgt STOPped.
Previous post should have said:
I believe that version 188.8.131.52 requires Administrator to run.
I'l post a less restricted version soon.
Version 184.108.40.206 has been posted.