Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Novlib 3.30 Online Reference - <b> itmprpvalget() / itmprpvalset()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 ItmPrpValGet() / ItmPrpValSet()
------------------------------------------------------------------------------
 Warning:
 USE WITH EXTREME CAUTION.

 Serious damage can be done to the bindery if misused.

 Purpose:
 Get / set an item property value.

 Syntax:
 lpbyValue = ItmPrpValGet(lpszObjName, iObjType,
       lpszPropName, iSegment )
 lpbyValue = ItmPrpValSet(lpszObjName, iObjType,
       lpszPropName, iSegment, lpszNewValue )

 Parameters:
 lpszObjName  The object name.
 iObjType     The object type.
 lpszPropName The property name.
 iSegment     The segment number.
 lpszNewValue The new property value.

 Returns:
 A character string of length 128.

 Description:
 ItmPrpValGet() returns the entire 128 byte segment of the specified
 property value. lpszObjName is the object name and iObjType its type.
 lpszPropName is the property name and iSegment is the segment.

 Property values are split into segments of 128 bytes each and are stored in
 binary, so can contain information in any form. The information must always
 be passed to ItmPrpValGet() or ItmPrpValSet() as a string.
 Some properties, such as IDENTIFICATION, contain a user's full name in
 string form, while others contain numeric information.

 ItmPrpValSet() sets the property value to lpszNewValue and returns
 the previous setting if successful or an empty string if an error occurs.

 Example:
 // To change the full name of user JIM to Jim Smith, which will be a
 // string contained in segment 1 of a property called IDENTIFICATION:
 lpbyName = "Jim Smith"+CHR(0)+SPACE(118)
 lpbyOldName = ItmPrpValSet("JIM", OT_USER,;
              "IDENTIFICATION", 1, lpbyName )
 lpbyNewName = ItmPrpValGet("JIM", OT_USER,"IDENTIFICATION",1)
 if ( !empty( lpbyNewName ) )
    ? "User JIM's full name is now", NewName
 endif

 Notes:
 If an empty string is returned, check NWErrorGet().

 In CA-Clipper, CA-VO and Visual Basic, to pass binary information it is
 necessary to build a string using the Chr() function, e.g. Chr(16) + Chr(3)
 etc.
 For more information on properties and their values, see Bindery Functions,
 Chapter 3.
 May require Supervisor equivalence.

See Also: ItmPrpBytGet() / ItmPrpBytSet() ItmPrpStrGet() / ItmPrpStrSet() ObjPrpLst()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson