[Chapter 21] Reference: JSObject.setMember()
Author: David Flanagan
Date: Fri Aug 29 11:17:09 1997

#

| Chapter 21 JavaScript Reference |

# JSObject.setMember() Java Method

## Name

JSObject.setMember() Java Method---set a property of a JavaScript object

## Availability

Part of the netscape.javascript package included with Navigator 3.0

## Synopsis

    public void setMember(String name, Object value)

### Arguments

`name`

  The name of the property to be set in the JSObject.

`value`

  The value that the named property should be set to.

### Returns

nothing

## Description

The `setMember()` method of the Java JSObject class sets the value of a named property of a JavaScript object from Java. The specified `value` may be any Java Object. Primitive Java values may not be passed to this method. In JavaScript, the specified `value` will be accessible as a JavaObject object.

## See Also

"JSObject", Chapter 19, LiveConnect: JavaScript and Java

JSObject.removeMember() |  | JSObject.setSlot()