Difference between revisions of "OBJECTWRITE()"

From Lianjapedia
Jump to: navigation, search
m (1 revision)
 
(6 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
==Purpose==
 
==Purpose==
 
Function to write an external binary file from an object field
 
Function to write an external binary file from an object field
 
  
 
==Syntax==
 
==Syntax==
 
OBJECTWRITE(<filename>,<object field>[,<expL>])
 
OBJECTWRITE(<filename>,<object field>[,<expL>])
 
  
 
==See Also==
 
==See Also==
[[BINCLOSE()]], [[BINCREATE()]], [[BINOPEN()]], [[BINREAD()]], [[BINWRITE()]], [[OBJECTREAD()]], [[OBJECTTYPE()]],  
+
[[BINCLOSE()]], [[BINCREATE()]], [[BINOPEN()]], [[BINREAD()]], [[BINWRITE()]], [[OBJECTREAD()]], [[OBJECTSIZE()]], [[OBJECTTYPE()]]
 
+
  
 
==Description==
 
==Description==
The OBJECTWRITE() function writes an external binary file from a Recital Object field.  The OBJECTWRITE() function returns .T. if the external binary file was created successfully, and .F. otherwise.
+
The OBJECTWRITE() function writes an external binary file from an Object field.  The OBJECTWRITE() function returns .T. if the external binary file was created successfully, and .F. otherwise.
  
The name of the file to create can be specified in the parameter <filename>.  This can be any valid Recital/4GL expression that returns a valid filename.  The filename can also be an empty string, providing that the logical expression <expL> is true (.T.).  In this case, a unique temporary file name will be generated and the Object written to this file, with the file name being returned from OBJECTWRITE().
+
The name of the file to create can be specified in the parameter <filename>.  This can be any valid expression that returns a valid filename.  The filename can also be an empty string, providing that the logical expression <expL> is true (.T.).  In this case, a unique temporary file name will be generated and the Object written to this file, with the file name being returned from OBJECTWRITE().
  
The Recital object field containing the data to be written, is specified in the parameter <object field>, and must be a valid field in the currently selected workarea.
+
The Object field containing the data to be written, is specified in the parameter <object field>, and must be a valid field in the currently selected workarea.
  
  
Line 27: Line 24:
 
</code>
 
</code>
  
 
==Products==
 
Recital, Recital Server
 
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]
[[Category:Binary File Access]]
+
[[Category:Object Storage Functions]]
[[Category:Binary File Access Functions]]
+
[[Category:Lianja VFP Extensions]]
 +
[[Category:VFP Function Extensions]]

Latest revision as of 08:28, 4 February 2013

Purpose

Function to write an external binary file from an object field

Syntax

OBJECTWRITE(<filename>,<object field>[,<expL>])

See Also

BINCLOSE(), BINCREATE(), BINOPEN(), BINREAD(), BINWRITE(), OBJECTREAD(), OBJECTSIZE(), OBJECTTYPE()

Description

The OBJECTWRITE() function writes an external binary file from an Object field. The OBJECTWRITE() function returns .T. if the external binary file was created successfully, and .F. otherwise.

The name of the file to create can be specified in the parameter <filename>. This can be any valid expression that returns a valid filename. The filename can also be an empty string, providing that the logical expression <expL> is true (.T.). In this case, a unique temporary file name will be generated and the Object written to this file, with the file name being returned from OBJECTWRITE().

The Object field containing the data to be written, is specified in the parameter <object field>, and must be a valid field in the currently selected workarea.


Example

? objectwrite("myicon.gif",ICONS)
.T.
? objectwrite("",PHOTO,.T.)
_0049e10001.gif