Buttons to send html text to textfield
How do I insert html text to a dynamic textfield?
The textfield's instance is called myDynamic. The first button is called button1_btn. I've read on htmlText and multiline, but I can't figure out how to simply attach a text to a button and, when the button is pressed, the htmlText is sent to the field.
var firstText = "";
firstText.multiline = true;
firstText.htmlText = "<p>test.</p>";
button1_btn.addEventListener(MouseEvent.CLICK, myInner);
function myInner (m:MouseEvent):void {
myDynamic.htmlText = firstText;
That should be working, but for some reason it's not, so I'm guessing the problem lies with the textfield, because I tested the button by changing the function to gotoAndStop and it seems to be working, but only under some odd condition. I created the textfield manually, not with AS3, but that shouldn't make any difference, since I gave it an instance name. I work with scenes (not my choice) and I'm noticing some odd behavior, and I wonder if it may have anything to do with my problem.
For example, when I change the function to gotoAndStop (1, "del2"), the button, which is directed to del2 (part 2) will not work if you click on del3 (part 3) right away; however, if you click on del2 first, then on del3 again, and you click the button, then it's working. As for the textfield, it won't work either way; the only thing I've noticed is that if you go to del2 and back to del3, a mystical "e" appears. I wish I could explain myself better, so instead I invite you to check it out (it will only take you 20 seconds).
How to reproduce the 'error':
1. Go to http://studenter.miun.se/~stti1400/test2.swf;
2. Click on Del3;
3. Click on the yellow button in the upper left corner, under "1" (it doesn't work);
4. Now click on Del2;
5. Click on Del3;
6. Notice the "e"; now click the same button as before (it takes you to del2).
In case you want to check the fla-file: http://studenter.miun.se/~stti1400/test2.fla
I played around a bit, changing the text of the variable to something else, like "okokokokok"; the "e" doesn't appear then. I first thought the "e" was a fragment of the text, with the rest of the text not showing.
Similar Messages
-
hai,
I like to send some html messages through the javamail, is there any way to achieve this ? If anyone knows about this please let me know.
Thanks,
Bala.Use the following:
MimeMessage message = new MimeMessage(session);
// for html
message.setContent(mailMsg, "text/html");
// for plain text
message.setContent(mailMsg, "text/plain"); -
Send html mail with navigateToURL(new URLRequest('mailto:
hi!
do you think its possible, to send html text to the email client of the mobile device?
i tried different ways, but without success.
Way 1
navigateToURL(new URLRequest('mailto:[email protected]'+'?subject=Subject'+'&body= <html><body>Hello world<br><img src="http://www.republicofcode.com/wp-content/uploads/2012/04/Pins2_300_250.png"></body></html>'));
Way 2
var hdr:URLRequestHeader = new URLRequestHeader("Content-type", "text/html");
var request:URLRequest = new URLRequest('mailto:[email protected]?subject=Subject&body=<html><body>Hello world<br><img src="http://www.republicofcode.com/wp-content/uploads/2012/04/Pins2_300_250.png"></body></html>');
request.requestHeaders.push(hdr);
navigateToURL(request);
Maybe i need another content type than text/html?
In the reference i've read, that the default one is: application/x-www-form-urlencoded
http://help.adobe.com/de_DE/FlashPlatform/reference/actionscript/3/flash/net/URLRequest.ht ml#contentType
Any ideas?you could try:
function submitPoll(e:MouseEvent):void {
//sending the email stuff
var request:URLRequest = new URLRequest("mailto:[email protected]"+"?subject=Subject"+"&body= Hello world ");
navigateToURL(request, "_blank");
request.method = URLRequestMethod.POST; -
Isn't it possible to send Html Mail through navigateToUrl() with contentType "text/html" for Android ? please suggest any workaround
ThanksAHHHH
What you can do to make HTML for Apple Mail is to make it in an HTML editor, open it with Safari use CMD+i - a new mail message will appear in a moment with the web page in the email body.
You can't do any major editing in Mail, you'll have to go back to the HTML file. But it works.
You can also use Copy (from a web page) and then (Edit) Paste as HTML (that what Paste as HTML is for, not for creating HTML email). You can also user Paste as HTML to copy/paste a HTML email you receive or part of a HTML email. -
When sending a PDF, firefox sends a text / html
When sending a PDF, firefox sends a text / html.
They cant open the PDF there I sendCan you post a link?
IE usually does content sniffing to see which file is received, but Firefox require the correct MIME type and will display the file as text if the server sends the file as text/plain as many servers do in such a case.
You can check the HTTP response headers with the Live Http Headers extension.
*Live Http Headers: https://addons.mozilla.org/firefox/addon/live-http-headers/ -
I downloaded the new version of firefox, now I cant watch any movies, the html text box is totally gone, and so is the back and forward website buttons, please help? can i just have the old version back?
Not sure whether for instance you initially had a Yahoo optimised version of Firefox, and have now overwritten it with an official Mozilla version. Although the Mozilla version should NOT add unwanted features, but the Yahoo version may well do.
If you merely need to find the Yahoo emails page quickly just add it as a bookmark or as a bookmark on the Bookmarks toolbar and make sure that is visible.
Clicking the star icon on the location bar whilst looking at your emails will bookmark the page.
* [[How to use bookmarks to save and organize your favorite websites]]
* [[Bookmarks Toolbar - Display your favorite websites at the top of the Firefox window]]
I do not use Yahoo myself,and am not sure what add-ons are available. You could search yourself using
* FirefoxButton -> add-ons
** see [[Find and install add-ons to add features to Firefox]]
** examples [https://addons.mozilla.org/en-us/firefox/addon/yahoo-toolbar/ yahoo toolbar] & [https://addons.mozilla.org/en-us/firefox/addon/yahoo-mail-notifier/ mail notifier]
* also look at Yahoo's own information such as http://help.yahoo.com/tutorials/toolbar/cl3/c3_ff_toolbar1.html -
Hi,
I would like to find a nice solution to the following
problem:
I have a large HTML text containing text and images
(<img>) inside a source TextField. I need to split this
content into several TextField's of a fix width and height so that
no scrolling is required.
I tried to use all the new goodies that AS3 provides
(getLineText(), bottomScrollV, etc). They are very helpful and if I
had normal text (no HTML tags) to deal with, I could split the
content without a problem. My problem is to do this on a HTML
content. It is very difficult to find the HTML version of a
splitted content.
Does anybody have an idea I could do this job?
Any help is greatly appreciated.no, your small textfields can be assigned text until they
their maxScrollV property exceeds one. then remove text from the
end of the small textfield's text property until its maxScrollV
property decreases to one AND you have a logical place to break the
text at which point you start assigning text to the next small
textfield. -
How can i enable the html:text box when clicking the html:button
Hi,
i have a text box which is disabled defaultly and i want to enable it when i click on submit button.
<html:button property="new" value="new">
<html:text property="name" disabled="true"/>
how i will enable that text filed? please tell me?
Thanks,
swarupatry using javascript onclick attribute:
onclick="document.form.name.disabled=false"
m -
How do I send "unlimited" text in a parameter using "POST" in Ajax
I'm trying to send large amounts of text data to the server using POST rather than GET, using Ajax
However, I am only able to send a max of 9.76 kb
I start with a jsp page, which calls a javascript method that utilises Ajax, which sends the text in a parameter in a XMLHttpRequest object
to a servlet. The text is derived from options values in a multi select combo box.
Here's my code:
Code snippet from .jsp page:
<table>
<form name="form1" id="form1" method="POST">
<tr>
<td>
<select name="sel" id="sel" multiple="multiple" size="0"></select>
</td>
<td>
<input type="button" id="sendOpts" name="sendOpts" value="Send Options" onClick="jsObj.sendOpts()">
</td>
</tr>
</form>
</table>Code snippet from jsObj.js file:
//=================================================
// jsObj object
//=================================================
jsObj = new jsObj();
function jsObj() {
this.sendOpts = function() {
if(!confirm('Send Option Values?'))
return;
if (window.XMLHttpRequest) { // code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
} else { // code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
xmlhttp.onreadystatechange=function() {
if(xmlhttp.readyState==4) { // 4 = The request is complete
if (xmlhttp.status==200 || window.location.href.indexOf("http")==-1) {
alert(xmlhttp.responseText); // When I copy and paste all the text from this alert to text editor and save the file, the largest the file can be is 9.76 kb.
var url = 'testSize'; // Servlet that simply retrieves the sent String in a parameter and sends it back to this method
var sel = document.getElementById('sel');
var str = sel.name + '=';
var delim = ':';
for(var i = 0; i < sel.length; i++) {
str += encodeURIComponent(sel.options.value + delim); // 'encodeURIComponent' encodes any special characters within the parameter values
xmlhttp.open("POST",url,true);
xmlhttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); // This is needed for any POST request made via Ajax
xmlhttp.send(str); // send the parameter and it's value to the servlet
}Code snippet from 'testSize' servlet:package test;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.*;
public class TestSize extends HttpServlet {
public synchronized void doGet(HttpServletRequest request,
HttpServletResponse response) throws ServletException,IOException {
PrintWriter out = null;
try {
response.setContentType("text/html");
out = response.getWriter();
String str = request.getParameter("sel");
str = str.substring(0, str.length()-1); // cut off last delimiter
out.println(str);
} catch (Exception e) {
public synchronized void doPost(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
doGet(request, response);
}Any help greatly appreciated.
Edited by: Irish_Fred on Feb 25, 2010 5:14 AMYes, I tried that.
I set the "ACTION" of the form to the servlet and then used the form.submit() method to POST the text to the servlet.
i.e.: I selected many options in the select combo, concatenated them to one string, set the 'value' property of a form text field to
this string, did a 'form.submit()' to the servlet and I was able to send a much larger amount of text.
( The .txt file I saved from the resulting text equaled about 30 kb in size, so obviously I can send much more
data this way. )
However, I want to use Ajax, so I don't have to reload the page. I 'borrowed' the Ajax part of the code from a website:
http://www.javascriptkit.com/dhtmltutors/ajaxgetpost2.shtml
and I presumed that because the author used "POST" as opposed to "GET", I would be able to send larger
chunks of data. Obviously not, or there's another reason for the limit of data I can send using my present code,
which I'm not seeing. I'm fairly new to jsp, Ajax & Servlets, so this is no surprise.
If anyone can point out to me where I'm going wrong, I'd greatly appreciate it. Cheers. -
Problen when Sending the text file as attachment to the external mail
HI,
I am sending the text file as an attachment to a aexternal mai. mailing is going with text file attachment, but text file is empty. No information in the file is going, only empty text file is going. I am sending the code iam using. Please suggest, if I need to change any passing parameters orany other other solution.
tables: knb1,kna1,adr6,ITEMSET,bsid,TSP01.
INTERNAL TABLES
DATA: BEGIN OF it_kna1 occurs 0,
KUNNR LIKE KNA1-KUNNR,
ADRNR LIKE KNA1-ADRNR,
END OF it_kna1.
DATA: BEGIN OF it_email occurs 0,
ADDRNUMBER LIKE ADR6-ADDRNUMBER,
SMTP_ADDR LIKE ADR6-SMTP_ADDR,
END OF it_email.
DATA: BEGIN OF it_bsid occurs 0,
KUNNR LIKE BSID-KUNNR,
BUKRS LIKE BSID-BUKRS,
END OF it_bsid.
DATA: BEGIN OF it_final occurs 0,
KUNNR LIKE KNA1-KUNNR,
ADRNR LIKE ADR6-ADDRNUMBER,
EMAIL LIKE ADR6-SMTP_ADDR,
END OF it_final.
DATA: BEGIN OF BUFFER OCCURS 10000,
TEXT(255) TYPE C,
END OF BUFFER.
data:xtext type solix_tab." occurs 0 with header line."line.
data:xi_pdf type soli_tab.
DATA: OBJPACK LIKE SOPCKLSTI1 OCCURS 2 WITH HEADER LINE,
OBJHEAD LIKE SOLISTI1 OCCURS 1 WITH HEADER LINE,
OBJBIN LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
OBJTXT LIKE SOLISTI1 OCCURS 10 WITH HEADER LINE,
RECLIST LIKE SOMLRECI1 OCCURS 5 WITH HEADER LINE,
DOC_CHNG LIKE SODOCCHGI1,
PARAMS LIKE PRI_PARAMS,
ARPARAMS LIKE ARC_PARAMS,
DAYS(1) TYPE N VALUE 8,
COUNT(3) TYPE N VALUE 1,
VALID TYPE C,
RECEIVER(30),
STR(256).
data: spoolid type tsp01-rqident,
pdf_table like tline occurs 0 with header line,
v_bytecount type i,
itab_pdf like tline occurs 10 with header line,
xi_pdf like tline occurs 0 with header line,
xi_pdf like buffer occurs 0 with header line,
xi_pdf_1 like xi_pdf,
v_length(2) type p,
html like solisti1 occurs 0 with header line,
xi_temp like bapiqcmime occurs 0 with header line,
xi_mime(255) type c occurs 0 with header line.
VARIABLES
data: g_email type adr6-smtp_addr,
TAB_LINES LIKE SY-TABIX,
G_FLAG(1) TYPE C.
g_norm(1) TYPE C,
g_shbv(1) TYPE C,
g_merk(1) TYPE C,
g_park(1) TYPE C,
g_apar(1) TYPE C.
data: l_lines type i,
line1 type i,
l_temp(500) type c,
l_offset type p,
l_lineslen(2) type p,
l_mimelen(2) type p,
v_spono like tsp01-rqident,
l_tabix like sy-tabix.
*****VIA SELECTION-SCREEN
ENDFORM. " SEND_TO_SPOOL
*& Form GET_SPOOL_ID
*& Form CONVERT_SPOOL_TO_PDF
*& Form SEND_MAIL
FORM SEND_MAIL .
data:l_lin like sy-tabix,
l_lint like sy-tabix,
it_list like abaplist occurs 0,
l_newline(2) type x value '0D0A'.
*--Data for the status output after sending
data: user_address like sousradri1 occurs 1 with header line,
sent_to_all like sonv-flag.
clear: reclist, reclist[],
objtxt , objtxt[],
objpack, objpack[],
objbin , objbin[],
doc_chng.
*--move list to office table objbin
*--Start of Changes to support PDF attachments - UB20030116
loop at html.
objbin-line = html-line.
append objbin.
clear objbin.
endloop.
loop at xi_pdf.
objbin-line = xi_pdf-text.
append objbin.
clear objbin.
endloop.
*--We may write additional text to the main document
*--For faxing this will be the cover page. Like sending from SAPoffice
*--the layout set Office-Telefax will be used.
objtxt-line = 'NOTE : Please Consider the below Headers'.
append objtxt.
clear objtxt.
objtxt-line = 'Assignment --> Purchase order number '.
append objtxt.
clear objtxt.
objtxt-line = 'Document --> Invoice No '.
append objtxt.
clear objtxt.
objtxt-line = 'Amount In DC --> Amount Due '.
append objtxt.
clear objtxt.
objtxt-line = ' '.
append objtxt.
clear objtxt.
objtxt-line = ' '.
append objtxt.
clear objtxt.
objtxt-line = 'Please find attached statement for this week'.
append objtxt.
clear objtxt.
objtxt-line = ' '.
append objtxt.
clear objtxt.
objtxt-line = 'This is an AUTO GENERATED MAIL'.
concatenate objtxt-line 'Please Do not reply to this mail' into
objtxt-line separated by ' '.
append objtxt.
clear objtxt.
describe table objtxt lines tab_lines.
read table objtxt index tab_lines.
*--Create the document which is to be sent
doc_chng-obj_name = 'List'.
doc_chng-obj_name = 'SAPRPT'.
doc_chng-obj_descr = 'Customer statement for the week'.
concatenate 'Customer statement for '
sy-datum into
doc_chng-obj_descr
separated by ' '.
doc_chng-doc_size = ( tab_lines - 1 ) * 255 + strlen( objtxt ).
*--Fill the fields of the packing_list for the main document:
*--It is a text document
clear objpack-transf_bin.
*--The document needs no header (head_num = 0)
objpack-head_start = 1.
objpack-head_num = 0.
*--but it has a body
objpack-body_start = 1.
objpack-body_num = tab_lines.
*--of type RAW
objpack-doc_type = 'RAW'.
append objpack.
*--Create the attachment (the list itself)
describe table objbin lines tab_lines.
*--Fill the fields of the packing_list for the attachment:
*--It is binary document
objpack-transf_bin = 'X'.
*--we need no header
objpack-head_start = 1.
objpack-head_num = 0.
*--but a body
objpack-body_start = 1.
objpack-body_num = tab_lines.
*--of type G_DOC_TYPE
objpack-doc_type = 'PDF'. "commented on 12/13/2007
objpack-doc_type = 'TXT'. "commented on 12/13/2007
objpack-obj_name = 'Attachment'.
objpack-obj_descr = 'Customer Statement'.
concatenate 'Customer Statement' sy-datum into objpack-obj_descr.
objpack-doc_size = tab_lines * 255.
append objpack.
reclist-receiver = g_email.
reclist-rec_type = 'U'.
reclist-com_type = 'FAX'.
append reclist.
data:xi type soli.
xi-line = 'haisdgsfsdf'.
append xi to xi_pdf.
xi-line = 'haisdfdsfd'.
append xi to xi_pdf.
xi-line = 'haisfgsdfsd'.
append xi to xi_pdf.
xi-line = 'haisdfsgfsdgg'.
append xi to xi_pdf.
*xi_pdf-text = 'hai'.
*append xi_pdf.
*xi_pdf-text = 'hai'.
*append xi_pdf.
*xi_pdf-text = 'hai'.
*append xi_pdf.
*xi_pdf-text = 'hai'.
*append xi_pdf.
CALL FUNCTION 'SO_SOLITAB_TO_SOLIXTAB'
EXPORTING
ip_solitab = xi_pdf[]
IMPORTING
EP_SOLIXTAB = xtext[].
**--Send the document by calling the SAPoffice API1 module for sending
**--documents with attachments
call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = doc_chng
PUT_IN_OUTBOX = 'X'
COMMIT_WORK = 'X'
IMPORTING
sent_to_all = sent_to_all
TABLES
packing_list = objpack
object_header = objhead
contents_bin = objbin
contents_txt = objtxt
contents_hex = xtext
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
operation_no_authorization = 4
others = 99.HI,
There are lots of bugs.
Please refer this sample program to fix it.
http://www.sapdevelopment.co.uk/reporting/rep_spooltopdf.htm
Best regards,
Prashant -
So i go to send a text and when i hit send it closes everything and goes back to the home scren. i have restarted it and reset it but nothing works.
Try restarting your iPhone by holding down the on/off and the home buttons at the same time until you see the Apple logo.
-
Hi,
i have just updated my iphone 4 16gb to an iphone 5 16gb
The iphone 4 had horrific problems, for example: Cutting out on calls, it going silent, me not being able to hear the person i was speaking to and them being able to hear me, and then visa vera.. also the main button at the bottom started to break.. my text messages weren't sending and then when they did they would send several of the same one.. also with mixed messages in them.. some of the texts had been form ages ago and had been deleted anyway and bits of them would re appear in the middle of the text, but only show to the person recieveing the text.
I thought all of this might have been some water damage as i had nearly had it for 2 years... However on Tuesday.. ( 29th Jan) i recieved my new upgrade of the iphone 5.. i was so excited, but then today.. 2 days after recieving it, its starting to do EXACTLY the same things my old phone did... cutting me off, going quiet on the phone, not sending texts, then sending several ones... sending mixed texts. Safe to say i am fuming!!! i am with vodafone and rang them today asking why?! they said it couldnt be my handset as its a new one, couldnt be the sim because thats new too so it must be the area signal.. so she checked for me.. came back to me and said that the signal in my area is perfectly fine....?!?!?! that makes it even worse!!! so i have asked to return it....!! i was going to go with a different provider thinking that it was vodafone??but after looking on here it seems like its apple? i am very disappointed as i love everything else about the phone, but its impossible to have a phone like this! especially when i use it for work too!My wife is having the same problems as a reciever. She works in a school as a teaching assistant and her teacher sends messages that are mixed with previous texts from ages ago.
Can anyone shed some light on this problem or is it only her and this poster?
2m42s -
I have a new Ipad and when I try to buy an app it asks for my questions! I dont remember them so I press the button that send me an email to reset them. Ive sent it various times but it doesnt arrive. please help I need this app for school!!!
See Kappy's great User Tips.
See my User Tip for some help: Some Solutions for Resetting Forgotten Security Questions: Apple Support Communities https://discussions.apple.com/docs/DOC-4551
Rescue email address and how to reset Apple ID security questions
http://support.apple.com/kb/HT5312
Send Apple an email request for help at: Apple - Support - iTunes Store - Contact Us http://www.apple.com/emea/support/itunes/contact.html
Call Apple Support in your country: Customer Service: Contacting Apple for support and service http://support.apple.com/kb/HE57
Cheers, Tom -
I just got the i phone 4 on Friday and it has shut off and not come back on twice. I was able to get it to come on by holding the top button down for a few seconds but i don't want to have to do that. Also, i am having a problem with texting, i will send a text and the person on the other end says that I have sent a blank text. Just need to know if this is something that is going to continue because if so then I will take it back and get a Droid
Assuming the phone isn't jailbroken, the basic steps (as needed) are:
Restart phone (you already did this)
Reset phone
Restore phone in iTunes using a backup
Restore in iTunes as new, without using a backup
See appendix B of the User Guide for details
http://manuals.info.apple.com/en_US/iPhone_iOS4_User_Guide.pdf
If your phone is jailbroken, this is the most frequent cause of the problems you described. Restoring could permanently brick the phone.
Note that your iOS is old and the current version is 4.2.8. It's odd that it wasn't updated when your activated your phone in iTunes, being that you got it last Friday. -
Outlook 2010 "Send Plain text only" not working for individual contacts
We have a Outlook 2010/Exchange 2007 environment
If you go to Outlook Properties of a contact and change from "Let Outlook decide the best sending format" to "Send Plain text only", it is supposed to force Outlook to send a Plain text
email
to that contact.
But it is still sending HTML. This is happening with any contact I try this with.
While composing the email I can change it to Plain text manually and that works fine.
Not sure what gives...Hi,
I recommend that you check the global remote domain setting if set to send plain text.
If not , the remote domain setting will override the change of the contact's properties when sending email out.
More details refer to the following article:
http://technet.microsoft.com/en-us/library/bb232174(v=exchg.141).aspx
Remote domain settings Remote domains define the settings for outgoing message transfers between the Exchange 2010 organization and domains outside the Active Directory forest. Even if you don't create remote domain entries
for specific domains, there's a predefined remote domain named Default that applies to all remote address spaces (*).
Hope this helps!
Thanks.
Niko Cheng
TechNet Community Support
Maybe you are looking for
-
External hard drive not recognized after time machine locked up
I was backing up to an external hard drive (300GB Western Digital) and time machine locked up. I had to shut down the computer and restart. Now the external hard drive does not show up on the desktop? I can see it in disk utility but I am not able to
-
High ram usage when loading high resolution images
Hello, I'm wondering why Firefox almost hangs my system while opening high-resolution images like this one (save your data, you have been warned): http://minecraft.1favre.de/output.png While opening, it involves X process to use CPU and a lot of memo
-
Two presentation Servers on Same Machine
I'm deploying my OBIEE in Oracle App Server on LINUX. I'd like to add a second presentation server pointing to a common RPD/BI Server. I see the following options: • Using the same container I would just deploy the analytics folder a second time
-
Each time I create a Text Frame it appears colored with black?
Every time I create a Text Frame with the Type tool in InDesing CS5.5 in a document named "02_End.indd", (this happen only for this file) the it appears filled with black color. On the other documents this does not happen (the text frames are with no
-
How to include unticked songs in shuffle?
When I untick songs in my iTunes library, they are not included in shuffle anymore. I have for example a playlist with nothing but unticked songs. But when I start the shuffle function in that playlist, only one songs plays, and then the shuffle stop