Flex :: Restrict User To Copy Content From Textarea?
Nov 9, 2010I am trying to built something like this:
[URL]
User can not copy content from textarea in flex3. How can i implement this functionality?
I am trying to built something like this:
[URL]
User can not copy content from textarea in flex3. How can i implement this functionality?
I would like to disable copy event in the TextArea I'm using. To achieve so I added the following code block:
function initTA(){
var tf:IUITextField = body.mx_internal::getTextField();
tf.enabled = false;
}
<mx:TextArea id="body" creationComplete="initTA()" .../>
This is working fine unless the text area has lots of text inside in which case a scroll bar appears. After the scroll bar is being used by the user, the text area stopped blocking the copy event.
By the way, I am using text area for display purposes since I use rich text area format.
Does anyone know of a way to restrict a user from entering a number over 100 into a textinput field in flex? i.e. a user can enter any number between and including 0-100 but not 101
View 3 RepliesA web channel streaming service streams to a certain IP range, it only checks the IP in example.com/cmd.php?id=xxx (channel number) and outputs an rtmpe stream URL, nothing else.How do I trick it to get my local URL instead of the one on their server? I have considered squid proxy, but is there some way to do it with a firefox plugin or greasemonkey script?
Edit:I will try to specify:It's a streaming service from an ISP and cable provider. They stream for free to people on their IP's. On their webtv page, which is called webtv.example.com, there is a flash player. If you are not on an IP from their ISP, you can't stream anything but the test channel.When you try to change channel via. javescript:videoplayer_changechannel(xxx) it makes this HTTP request:
[URL]
If you are on one of their IP's you will get an RTMP URL, like this:
[URL]
This is what the flash player requests, and if it get's this response it load the channel requested. There is no HTML on the php page, just the URL. Note that the rtmp URL is static.If you are not on one of their IP's it will return a random sentence (something stupid, the programmers having fun).I wan't to trick the flash player into getting the right value, even though it's not on one of the ISP's IP's.
I have an mx:TextArea and I want its height to be the same as its content height. There is nothing fancy - just a text area and text that is not editable. I need a simple and reliable way to make the control fit and show all the text without vertical scroll - something like auto resizing. Also my control's text will be set only once and will not change as it will not be editable.
<mx:TextArea id="myTextArea"
editable="false"
width="100%"
verticalScrollPolicy="off" >
<mx:text>
[Code] .....
There is one more post here on the same topic but it is not relevant to me because the setup there is a lot more complicated as it includes styling and binding.
Is it possible to get content of each line from spark's TextArea or RichText?
What I want to achieve it to split textarea's (or richtext) content into rows and modify some of them.
I want to get the line count of the spark text area content.
View 1 RepliesI'm looking to take an object that contains String and Integer context and that has pushed upon a Stack and pop those specific contents into a display that the user can see. The display consists of two textareas and a label.I can't figure out how to access the individual parts of the Object to display them though..[code]
View 1 RepliesI have need to restrict user input. TextInput should restrict all special characters and punctuation. Any other characters are allowed. In java there is a regex patter:
replaceAll("\p{Punct}", "_")
Is there something similar in actionscript?
I want to have a webcam site where a user can broadcast their webcam and people can view it.
ActionScript Code:
netstream.publish("broadcast");
This was pretty easy to do.
The problem seems to be that anyone can broadcast over any netstream.
would someone be able to hijack a users broadcasting netstream?
could you publish through a php file to confirm sercurity?
ActionScript Code:
netstream.publish("http://example.com/netstreampublish.php?room=broadcast");
PHP Code:
<?php//perform security check is the real broadcaster//redirect to stratus?>
If I had my own stratus server, would I be able to do security checks before allowing broadcasting?
i have a question that is almost like other questions but with a small but very important difference. how can i restrict file types for user with a popup showed in the browser.
The standard file input of html can limit that with a command but it does not work in all browser so it is not an option. I do not want to validate the file extension after the user has chosen a file but before that, when he is choosing.[URL].. but it uploads the file after the user has chosen it, i do not want to do that, i want to upload it after the user submits the form.
So the problem looks like this that there are some ways of not letting the user send a not valid file but they are not good because, one is that i validate after the user have chosen the file and the other is that i upload the file before the user submits the form.
I just want a simple thing to not letting to "chose" a not valid file, it does not matter if it will be made with java script or flash, just let it work.
I would like to restrict user input to numbers only between letters. for example: the user is allowed to input "a2b", but "2ab" or "ab2" isn't allowed.
View 4 RepliesI want to restrict Delete key, Backspace key, and Enter Key in TextArea.ow to restrict these 3 keys.
View 1 Repliesi want hi i want to restrict user from entering starting space
in as2 i have this
function LTrim(str:String) {
for (var k = 0; k<str.length && str.charAt(k)<=" "; k++) {
[code]...
I am working on an application in which i have put one Multi line input text box. I want to allow user to enter data only up to 8 Lines. User can not enter more than 8 lines. So is there any solutions..??? I dont want to use MaxChars as it can restrict user to not enter more than predefined number of characters. I want to restrict user from entering more than predefined number of lines.
View 4 RepliesI have one file with thumb-scroll- xml loaded gallery Everything on the main time line under the _root I need to transfer this gallery to another FLA and make it in movie Clip So here is link to original FLA
What is happening now when I copy everything to new FLA even at the same position it dosent loud thumbs and picture
How to copying display objects (sprites, movieclips etc) while keeping thier content (graphics, added display objects etc)in AS3? The most commonly suggested solution by Kirupa (
[Code]...
I have a TextArea component called labels that will be populated by Strings in an Array called labelsArray.[code]...
I don't understand starting from "...specifying the end..." to the end. I don't understand how arrow keys come into play with formatting of text.
I have a TextArea component with a lot of content (images+text) - the content is coming from a xml file.. i need to print the textarea content and when i do - it is printing just the visible content area with scrollbar-is there anyway i can print the entire TextArea content using a print button on my flash file- im using AS2.
View 1 RepliesI am trying to record textArea user input into an xml file...
here is part of my code
ActionScript Code:
var comment = comment.text; //hello world
var names = name_in.text
[Code]....
how to assign a variable between xml tags ?
I'm trying to write a script that can copy multiple inputs that i've stored inside my array to the clipboard. Is it possible for me to get all my data inside "storage" array to the clipboard? All it seems to do is copy the last input given.[code]...
View 2 RepliesI need a way to copy the content of one movie clip (with many frames) into another dynamically using as3. I have created one mask container and i am filling it with the images from xml i.e. MovieClip(root).myContainer.forward.imageContainer .addChild(myspriteImage). How can i dinamicaly dublicate the movieclip myContainer with all child in it, so i could dinamicaly put ieach image in each container?
View 1 RepliesI am trying to make a flash file that has wmode=transparent that takes up 100% width and height of the browser. I need to take a copy of the contents underneath the flash (the HTML page its floated over) and use that BitmapData to manipulate the content visually.
View 2 RepliesI'm hoping to produce a CD of Captivate lessons to be accessed via a Flash menu. (Using Flash CS4, but with ActionScript 2). I can get the files to work from the disc, but as they are large files, they take less time to open if downloaded onto the user's machine first.
Is it possible to use some ActionScript to take the folder of files and copy them onto the desktop so that I can then point the menu items to the newly copied folder? I've seen that there is a download option in ActionScript but this seems to bring up a dialogue box and allows the user to place the files wherever they want. Ideally I'd like the process to be automatic.
in my project i am making one line graph using createEmptyMovieclip() function, and i want to add facility of making multiple copy of that graph to user and for that copy facility i am using duplicateMovieclip() function but when i execute that only parent object(Graph_mc) is copied and the child object(Line_mc) which is created with help of 'createEmptyMovieclip()' function inside the graph , does not copy.If i create same object (Line_mc) on '_root' it will copied.
my code is .....
//for create graph
onClipEvent(load){
ang = 0
spd = 2
[code]....
Is there a script similar to the image below that lets the user press a copy button to copy text to their clipboards (instead of right-clicking to copy)? Here's the URL where I got that image: [URL]. Where I can find a script to do implement that functionality?
View 2 RepliesI have created a simple Flash file using actionscript 2 (CS3) that allows a user to enter text into an input text field and then print the results. Now what I want to do is allow the user to save what they've typed in a .pdf. (I would prefer a .pdf, but I'm not married to that format.)
View 1 RepliesI used code that kglad suggested to add a button that copies the embed code for a SWF to the user's clipboard:
clip_btn.addEventListener(MouseEvent.CLICK,clipcopy);
function clipcopy(e:Event):void{
Clipboard.generalClipboard.setData(ClipboardFormats.TEXT_FORMAT, s);
[code].....
I have created a simple Flash file using actionscript 2 (CS3) that allows a user to enter text into an input text field and then print the results. Now what I want to do is allow the user to save a file containing the information they've entered. I would prefer a .pdf, but I'm not married to that format.
View 0 RepliesIs it possible to restrict flex bar chart y-axis count?I have a very big name coming in my y-axis and i want to reduce or restrict it to 5 characters and on rollover i want to display it in full.
View 1 Replies