this.editor.execCmd issue in Chrome

Hello

Please help me in this issue

In HtmlEditor editor there was some text.
this.editor.execCmd('InsertHTML', '<span id=' + id + '>'); this will insert only span into editor.. whole text will get disappeared after this line of execution.

when i tried var textTmp = this.editor.getValue();
textTmp doesnt contains anything except span..How to get the text in editor with sapn inserted at cursor,

Maybe the 'formatblock' command will work for that. Otherwise you will have to get the currently selected text and use InsertHTML to insert the span including that text (see HTMLEditor plugins for example).