Welcome to the Harris Geospatial product documentation center. Here you will find reference guides, help documents, and product libraries.


  >  Docs Center  >  Libraries  >  JBIU  >  PUSH

PUSH

PUSH

Name


    PUSH

Purpose


    Adds an element to the end of a (possibly non-existent) array.

Category


    Misc

Calling Sequence


    PUSH, Array, Value

Inputs


    Array: An array to which the values are to be added. The array
            is created if it doesn't already exist.
    Value: A value to be added to the end of Array. Must be the
            same type as Array.

Example


    IDL> PUSH, a, 5
    IDL> PRINT, a
        5
    IDL> PUSH, a, 8
    IDL> PRINT, a
        5 8

Modification History


    Written by: Jeremy Bailin
    12 June 2008 Public release in JBIU
ro push, array, value
ase size(array, /n_dimen) of
  0: array = [(value)[*]]
  1: array = [array, (value)[*]]
  else: message, 'Array cannot have more than 1 dimension.'
ndcase
nd



© 2018 Harris Geospatial Solutions, Inc. |  Privacy Policy
My Account    |    Store    |    Contact Us