[comp.windows.ms] "Not enough memory to run" error

simnet@ssc-vax.UUCP (Aileen Hsu) (10/18/90)

 I want to call the SYSTEM function inside my Microsoft Windows Application whenthe user select a particular menu item.  The problem is every time the
 application attempts to execute the statement, a window comes up with
 the Command title and says "Not enough memory to run".
 I'm using Windows 286 ver. 2.0 and Windows SDK ver. 2.0 running on an
 Everex 386 machine.  I have 640K conventional memory, 2 MB expanded
 and 4MB extended.  My config.sys file has the following entries:
       DEVICE=EMM.SYS AT 208 ND
       BREAK=ON
       BUFFERS=10
       FILES=20
       LASTDRIVE=E
       SHELL=C:\DOS\COMMAND.COM /P /E:512
       DEVICE=C:\SMARTDRV.SYS 512
       DEVICE=C:\HIMEM.SYS
       DEVICE=C:DOS\ANSI.SYS
       INSTALL=C:C:\DOS\FASTOPEN.EXE C:=(50,25)
       DEVICE=QUIKMEM2.SYS 256
       DEVICE=C:\UTIL\OX.SYS
IF I do the mem command after window is brought up, the machine still
has 450K conventional, 1.8MB expanded and 0 extended (don't know why)
memory left.  Is this not enough to call SYSTEM.  The Windows
application with the SYSTEM call is very simple, I created just to see
if it would work.
Can anybody out there help me with this since Microsoft no longer
provides free support for their SDK?
Any kind of help will be greatly appreciated.
Aileen Hsu

mutchler@zule.EBay.Sun.COM (Dan Mutchler) (10/18/90)

In article <3506@ssc-bee.ssc-vax.UUCP> simnet@ssc-vax.UUCP (Aileen Hsu) writes:

    I want to call the SYSTEM function inside my Microsoft Windows Application whenthe user select a particular menu item.  The problem is every time the
    application attempts to execute the statement, a window comes up with
    the Command title and says "Not enough memory to run".
    I'm using Windows 286 ver. 2.0 and Windows SDK ver. 2.0 running on an
    Everex 386 machine.  I have 640K conventional memory, 2 MB expanded
    and 4MB extended.  My config.sys file has the following entries:
	  DEVICE=EMM.SYS AT 208 ND
	  BREAK=ON
	  BUFFERS=10
	  FILES=20
	  LASTDRIVE=E
	  SHELL=C:\DOS\COMMAND.COM /P /E:512
	  DEVICE=C:\SMARTDRV.SYS 512
	  DEVICE=C:\HIMEM.SYS
	  DEVICE=C:DOS\ANSI.SYS
	  INSTALL=C:C:\DOS\FASTOPEN.EXE C:=(50,25)
	  DEVICE=QUIKMEM2.SYS 256
	  DEVICE=C:\UTIL\OX.SYS
   IF I do the mem command after window is brought up, the machine
   still has 450K conventional, 1.8MB expanded and 0 extended (don't
   know why) memory left.  Is this not enough to call SYSTEM.  The
   Windows application with the SYSTEM call is very simple, I created
   just to see if it would work.  Can anybody out there help me with
   this since Microsoft no longer provides free support for their SDK?
   Any kind of help will be greatly appreciated.  Aileen Hsu

Try making it "FILES=99". Windows appears to give "Not enough memory"
when it runs out of any system resource. I ran into this problem under
Windows 3.0 and changing the number of files seemed to fix it.
--

Dan Mutchler                       | ARPA/Internet:  mutchler@zule.EBay.Sun.COM
Sun Federal System Engineer        | UUCP:           ...!sun!mutchler
--------------------------------------------------------------------------
Flying back from Lubbock, I saw Jesus on the plane
Or maybe it was Elvis, You know they kind of look the same.
                     -- Don Henley

steve@wintermute.ucsd.edu ({Darkavich}) (10/18/90)

In article <MUTCHLER.90Oct18081743@zule.EBay.Sun.COM> mutchler@zule.EBay.Sun.COM (Dan Mutchler) writes:
>Try making it "FILES=99". Windows appears to give "Not enough memory"
>when it runs out of any system resource. I ran into this problem under
>Windows 3.0 and changing the number of files seemed to fix it.

One of the worst things you can do to a system is add files=99 to the
enviroment.  There is a big trade-off between memory and performance when
you do this.  I would suggest that you make buffers and files equal to 30.
That is what windows expects to see.

Steve Misrack
steve@ucsd.edu

marcs@crpmks.UUCP (Marc Snyder) (10/22/90)

In article <20960@ucsd.Edu> steve@wintermute.ucsd.edu ({Darkavich}) writes:
>In article <MUTCHLER.90Oct18081743@zule.EBay.Sun.COM> mutchler@zule.EBay.Sun.COM (Dan Mutchler) writes:
>>Try making it "FILES=99". Windows appears to give "Not enough memory"
>I would suggest that you make buffers and files equal to 30.
>That is what windows expects to see.

From what I remember from my Windows 3.0 installation, MicroSoft wanted
the buffers set to 10 for optimum windows performance under enhanced
mode.
--
Marc Snyder                     UUCP: ...philabs!crpmks!marcs
System Administrator                  ...gaboon!crpmks!marcs 
Ciba-Geigy Corporation
Hawthorne, New York          Work: 914.785.2284      Play: 914.347.6440

greggy@informix.com (greg yachuk) (10/25/90)

When just using Extended Memory, SMARTDRV.SYS must be loaded
*after* HIMEM.SYS. RAMDRIVE.SYS should also be loaded after
HIHMEM.SYS, but you don't seem to be using it.  If you load
SMARTDRV.SYS before HIMEM.SYS, it will end up with zero memory
for buffering.  This might be the cause of your problem.

I'm not sure how SMARTDRV.SYS interacts with Expanded Memory
(assuming that's what EMM.SYS is for).

Also, could there be contention between SMARTDRV.SYS and
QUICKMEM2.SYS?

simnet@ssc-vax.UUCP (Aileen Hsu) writes:


> I want to call the SYSTEM function inside my Microsoft Windows Application whenthe user select a particular menu item.  The problem is every time the
> application attempts to execute the statement, a window comes up with
> the Command title and says "Not enough memory to run".
> I'm using Windows 286 ver. 2.0 and Windows SDK ver. 2.0 running on an
> Everex 386 machine.  I have 640K conventional memory, 2 MB expanded
> and 4MB extended.  My config.sys file has the following entries:
>       DEVICE=EMM.SYS AT 208 ND
>       BREAK=ON
>       BUFFERS=10
>       FILES=20
>       LASTDRIVE=E
>       SHELL=C:\DOS\COMMAND.COM /P /E:512
>       DEVICE=C:\SMARTDRV.SYS 512
>       DEVICE=C:\HIMEM.SYS
>       DEVICE=C:DOS\ANSI.SYS
>       INSTALL=C:C:\DOS\FASTOPEN.EXE C:=(50,25)
>       DEVICE=QUIKMEM2.SYS 256
>       DEVICE=C:\UTIL\OX.SYS
>IF I do the mem command after window is brought up, the machine still
>has 450K conventional, 1.8MB expanded and 0 extended (don't know why)
>memory left.  Is this not enough to call SYSTEM.  The Windows
>application with the SYSTEM call is very simple, I created just to see
>if it would work.
>Can anybody out there help me with this since Microsoft no longer
>provides free support for their SDK?
>Any kind of help will be greatly appreciated.
>Aileen Hsu

-- 
Greg Yachuk		  Informix Software Inc., Menlo Park, CA 92025
greggy@informix.com | {uunet,pyramid}!infmx!greggy	(415) 926-6300
		--- I ask my brain for some assistance ... ---