---
title: "invokeDefaultMethod(withArguments:)"
framework: objectivec
role: symbol
role_heading: Instance Method
path: "objectivec/nsobject-swift.class/invokedefaultmethod(witharguments:)"
---

# invokeDefaultMethod(withArguments:)

Executes when a script attempts to invoke a method on an exposed object directly.

## Declaration

```swift
func invokeDefaultMethod(withArguments arguments: [Any]!) -> Any!
```

## Parameters

- `arguments`: The arguments to be passed to the default method.

## Return Value

Return Value The result of invoking the default method.

## See Also

### Invoking methods

- [invokeUndefinedMethod(fromWebScript:withArguments:)](objectivec/nsobject-swift.class/invokeundefinedmethod(fromwebscript:witharguments:).md)
