Setting the content of NSScrollViews

I’ve been trying in vain to get the content of scroll views to work. I even went to the XCode Dictionary, but to no avail.
The best I can come up with is ‘set contents of scroll view “logBox” of window “main” to “foobar”’ Any help? Thanks.