-
System.setClipboard issue
Hi,
I'm trying to save my text history on button click, but I'm messed up.
It only works works once and I'd like it to keep working in case the user opts not to leave the room and prefers to save his history later.
Besides this, nothing is saved. Where am I going wrong?
It's going to be hard for me to explain without attaching the file here, but it is about a chat.
Here's the code wheere I have things happening:
Code:
feedback_txt._visible = false;
textFeedback("Text del xat copiat al portapapers!! Recorda de copiar-lo a un arxiu i tornar-lo a desar");
function textFeedback(theFeedback:String) {
feedback_txt.text = theFeedback;
setTimeout(function () {
feedback_txt.text = "";
feedBack_mc.swapDepths(userList_lb);
}, 12000);
}
myMouse.onMouseUp = function() {
Selection.setFocus("input_txt");
exit_btn.onPress = function():Void {
if (!_global.isBusy) {
closeConnection();
}
};
saveChat_btn.onRelease = function() {
chat_txt._visible = true;
Selection.setFocus("chat_txt");
Selection.setSelection(0, chat_txt.text.length);
System.setClipboard(chat_txt.text);
feedback_txt._visible = true;
};
};
Can anything here affect the reason why the chat isn't copied in the clipboard?
-
.
Hi Cap,
At a quick glance try removing the saveChat_btn.onRelease = function .... outside of the mouseUp function, they probably cross one another.
probably best with the exit button too
-
Working better, but still no text is copied.
Can this have to do with operating system or html code?
I use Windows 8.1
-
.
Hi,
I wouldnt have thought it had anything to do with which windows you use.
-
No worries!
I just posted it in my site and it works http://webs.ono.com/jpdurba/xatAvata...bhistorial.swf if you 're curios...
but it only works once
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|