Sublime Forum

"unicode object is not callable" error using .statusMessage

#1

Hi,

[code]
import sublime, sublimeplugin

def onDone(s):
sublime.statusMessage(“AAA”)
sublime.setClipboard(s)
def onCancel():
sublime.messageBox(“Cancelled.”)

class SampleCommand(sublimeplugin.TextCommand):
def run(self, view, args):
view.window().showInputPanel(
“Hello”,“Initial text”, onDone, None, onCancel)[/code]

I get an error saying that “unicode object is not callable” for the 4th line (statusMessage). According to the API reference, you only need to pass in a string to the method. What’s the problem here?

0 Likes

#2

Hm… Restarting SU worked.

I think I did statusMessage = myArgument at some point, yes…

0 Likes