Memory
Previous Topic  Next Topic 

Product

Memory

Manufacturer

Standard Satellite Forms component

Website

http://www.satelliteforms.net/

Source code provided

Yes

Platform

PalmOS, PocketPC

Sample project(s)

Memory

Keywords

memory, allocate, byte


Memory is an extension which may be used to access and manipulate the handheld's dynamic memory.


Scripts API


The following methods are accessible from the scripting language. These are all global methods unless stated otherwise.


Global Method Usage:  [Name of method]

Example of usage:  MemoryAbout()



MemoryAbout()

Show Memory extension's about box. 

Sample usage:  MemoryAbout()


MemoryAllocate(integer)

Allocates dynamic memory. 

Sample usage:  Memory = MemoryAllocate(Size)



MemoryCompare(integer, integer, integer)

Compares dynamic memory. 

Sample usage:  Equal = MemoryCompare(Memory1, Memory2, Count) where 'Count' is the size, in bytes, of the memory to compare.



MemoryCopy(integer, integer, integer)

Copies dynamic memory. 

Sample usage:  Memory1 = MemoryCopy(Memory1, Memory2, Count) where 'Count' is the size, in bytes, of the memory to copy from 'Memory2' to 'Memory1'.



MemoryFree(integer)  

Frees dynamic memory (returns 0 for success). 

Sample usage:  Memory = MemoryFree(Memory)


MemoryGetByte(integer, integer)

Gets a byte from dynamic memory. 

Sample usage:  Byte = MemoryGetByte(Memory, Offset)



MemoryGetString(integer, integer, integer)

Gets a string from dynamic memory. 

Sample usage:  String = MemoryGetString(Memory, Offset, Count) where 'Count' is the size, in bytes, of the string and 'Offset' is how many bytes offset from the location pointed to by 'Memory' to start grabbing the string from memory.



MemoryReallocate(integer, integer)               

Resizes a block of dynamic memory. 

Sample usage:  Memory = MemoryReallocate(Memory, Size)



MemorySet(integer, integer, integer)             

Sets dynamic memory to a value. 

Sample usage:  Memory = MemorySet(Memory, Byte, Count) where 'Byte' is the value at which to set the memory and 'Count' is the amount of memory, in bytes, to set.



MemorySetByte(integer, integer, integer)

Sets a byte of dynamic memory at the location pointed to by the first variable plus the number of bytes offset set by the second variable. 

Sample usage:  Memory = MemorySetByte(Memory, Offset, Byte)


MemorySetString(integer, integer, string)

Sets a string of dynamic memory. 

Sample usage:  Memory = MemorySetString(Memory, Offset, String) where 'String' is the string being passed to memory location 'Memory' offset by 'Offset' number of bytes.


MemorySearch(integer, integer, integer, integer)      

Searches for first occurrance of Memory2 in Memory1.  Returns -1 if not found. 

Sample usage:  Offset = MemorySearch(Memory1, Size1, Memory2, Size2) where 'Size1' is the amount of memory to search starting from 'Memory1' and 'Size2' is the amount of memory to search from 'Memory2'.


MemoryReverse(integer, integer)     

Reverses a block of dynamic memory. 

Sample usage:  Memory = MemoryReverse(Memory, Size) where 'Size' is the amount of memory to reverse starting from memory location 'Memory'.



DocID: 10139  DocDate: 2005-07-18