Need EMS/XMS source. 
Author Message
 Need EMS/XMS source.

I have a problem with one of my DOS programms.

The program now contains to much records and this will not fit in the
conventional memory.

I tried the SWAG database and there are source codes for this problem but
none of them I can implement in my source:

The record looks like this:

type
  GamesRecord = record
    Del          : longint;
    GameTitle    : Str25;
    GameLabel    : Str20;
    Platinum     : boolean;
    GameGenre    : Str15;
    GameSystem   : Str5; {string to hold
    SalesCounter : integer;     { counter
    ListPrice,
    PPD          : Str8;
    Stock,                         { How
    MinStock,
    MaxStock     : byte;
    IsRetour     : boolean;
    Barcode      : Str13;
    Supplier     : Str25;
    Ordered      : byte;
    Releasedate  : Str8;
    MemoField    : array [1..2] of Str75;
  end;

and the problem starts here after the 751st record:

            if GetRecord
              then
                begin
                  inc (Times);
                  ClearMem := true;
                  GetMem (GSortPtr[Times], sizeof (GSrtRec));
                  GSortPtr[Times]^.GamesSrtRec := CurrRec;
                  GSortPtr[Times]^.RefNrPtr := RefNr;
                end;
          end;

So I need a GetEMSmem of GetXSMmem function and a good example how to
implement it in my source. Can somebody help me?

Regards.



Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.

Quote:

> So I need a GetEMSmem of GetXSMmem function and a good example how to
> implement it in my source. Can somebody help me?

<PLUG>
Check out the Free Pascal Compiler. Since it runs under 32 bit
protected mode, you can GetMem as much as you want, as long as there is
enough (virtual) memory available. URL:
<http://tfdec1.fys.kuleuven.ac.be/~michael/fpc>
</PLUG>

Jonas



Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.

Quote:

> I have a problem with one of my DOS programms.

> The program now contains to much records and this will not fit in the
> conventional memory.

Maybe you could try to compile the program for Protected Mode (requires you
to use Borland Pascal, not Turbo Pascal).


Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.
Here's a page has some source, one of which is an ems_xms unit I wrote more
than a few years ago.

http://home.istar.ca/~pjp/source.htm


Quote:

>I have a problem with one of my DOS programms.

>The program now contains to much records and this will not fit in the
>conventional memory.

>I tried the SWAG database and there are source codes for this problem but
>none of them I can implement in my source:

>The record looks like this:

>type
>  GamesRecord = record
>    Del          : longint;
>    GameTitle    : Str25;
>    GameLabel    : Str20;
>    Platinum     : boolean;
>    GameGenre    : Str15;
>    GameSystem   : Str5; {string to hold
>    SalesCounter : integer;     { counter
>    ListPrice,
>    PPD          : Str8;
>    Stock,                         { How
>    MinStock,
>    MaxStock     : byte;
>    IsRetour     : boolean;
>    Barcode      : Str13;
>    Supplier     : Str25;
>    Ordered      : byte;
>    Releasedate  : Str8;
>    MemoField    : array [1..2] of Str75;
>  end;

>and the problem starts here after the 751st record:

>            if GetRecord
>              then
>                begin
>                  inc (Times);
>                  ClearMem := true;
>                  GetMem (GSortPtr[Times], sizeof (GSrtRec));
>                  GSortPtr[Times]^.GamesSrtRec := CurrRec;
>                  GSortPtr[Times]^.RefNrPtr := RefNr;
>                end;
>          end;

>So I need a GetEMSmem of GetXSMmem function and a good example how to
>implement it in my source. Can somebody help me?

>Regards.



Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.

Quote:

>I have a problem with one of my DOS programms.

>The program now contains to much records and this will not fit in the
>conventional memory.

>I tried the SWAG database and there are source codes for this problem but
>none of them I can implement in my source:

Two choices really:

1. If you have BP7 you can compile in protected mode which gives you far
more memory;

2. If you can only compile in real mode you need to use XMS. Some code
in SWAG at http://www.gdsoft.com/swag/ and there is an XMS access unit
via http://www.pedt.demon.co.uk/ and lots of other sites.

--
Pedt



Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.

Quote:

> I have a problem with one of my DOS programms.

> The program now contains to much records and this will not fit in the
> conventional memory.
--snip--
> So I need a GetEMSmem of GetXSMmem function and a good example how to
> implement it in my source. Can somebody help me?

You can download source code for my EMS and my XMS units from my web
page.  Also included are text files describing how to use them.

--

(If you are a human, then you can figure out my real address.)

Come see me at my web site:
http://www.geocities.com/SiliconValley/Pines/9447



Mon, 02 Jul 2001 03:00:00 GMT  
 Need EMS/XMS source.

Quote:

>So I need a GetEMSmem of GetXSMmem function and a good example how to
>implement it in my source. Can somebody help me?

>Regards.

If you are using Turbo Pascal, take a look at TEmsStream in the Objects
unit.

It allows you to manipulate the EMS like a file:

Program Example;
uses objects;

var data1,data2:byte;
    EMS:TEmsStream;

begin
  data1:=100;
  data2:=0;
  Ems.Init(10,10);
  Ems.Write(data1,1);
  Writeln('Written to EMS : ',data1);
  Ems.Seek(0);
  Ems.Read(data2,1);
  Writeln('Read from EMS : ',data2);
  Ems.done;
end.



Tue, 03 Jul 2001 03:00:00 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. Need EMS/XMS source.

2. Swapping programs to disk/XMS/EMS before EXEC

3. Can you use EMS or XMS for stack?

4. Easiest ems/xms pointers

5. Easy Ems/Xms access?

6. looking for ems/xms unit

7. SOS : XMS/EMS in TP6

8. How do I use EMS or XMS memory???

9. VESA and XMS/EMS

10. HELP!!! XMS/EMS managing under Turbo Pascal 6

11. Allocate data in XMS/EMS

12. How du I use XMS/EMS memory?

 

 
Powered by phpBB® Forum Software