How to send a string to yahoo messenger ?
Hello,
I just wonder whether it is possible to write an java app which automatic send a string yahoo messenger chatroom. It would be fine if somebody give me hint where to look at ... if possible.
Thank in advance,
hodydo
I doubt that there's an API that you could call, but you might be able to do it with sockets. If you run a packet sniffer (like the open-source Ethereal) while running Yahoo messenger, you might be able to learn a bit about the protocol and try sending the tcp/ip data yourself using Java.
Similar Messages
-
How can i download and install yahoo messenger for Mac on OS X Yosemite?
how can i download and install yahoo messenger for Mac on OS X Yosemite?
If you need to purchase Snow Leopard contact Customer Service: Contacting Apple for support and service. The price is $29.00 plus tax. You will receive physical media - DVD - by mail.
Third-party sources for Snow Leopard are:
Snow Leopard from Amazon.com
Snow Leopard from eBay
After you install Snow Leopard you will have to download and install the Mac OS X 10.6.8 Update Combo v1.1 to update Snow Leopard to 10.6.8 and give you access to the App Store.
Snow Leopard General requirements
Mac computer with an Intel processor
1GB of memory
5GB of available disk space
DVD drive for installation
Some features require a compatible Internet service provider; fees may apply.
Some features require Apple’s MobileMe service; fees and terms apply. -
How can i install or download yahoo messenger to my IPAD 5.1.1 version?
How can i install or download yahoo messenger to my IPAD 5.1.1 version? Was it possible to download using google?
Was it possible to download using google?
You can only download apps from the Apps Store. Follow Simon's link. -
How to send a String to a Servlet using a HTTP POST
Well, I have designed a servlet that receives a HTTP POST, I was testing it using an HTML form to send (using POST) information, now, I have coded a Java App to send it a string, I don't know how to make the servlet recognize that info so it can make its work, I am posting both codes (Servlet & API) so anyone can guide me and tell me how and where to modify them
Servlet:
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import java.sql.*;
public class xmlwriter extends HttpServlet
public void service(HttpServletRequest req, HttpServletResponse res)
throws ServletException, IOException
ServletOutputStream salida = res.getOutputStream();
res.setContentType("text/HTML");
String cadena = req.getParameter("cadena");
File f1 = new File ("c:/salida.xml");
FileWriter out = new FileWriter(f1);
f1.createNewFile();
out.write(cadena);
out.close();
salida.println("OK");
Now, the JAVA API is:
import java.io.*;
import java.net.*;
public class HTTPSender {
public static void main(String[] args) throws Exception {
URL url1 = new URL
("http://localhost:8080/XMLSender/xmlwriter");//internal site
URLConnection UrlConnObj1 = url1.openConnection();
HttpURLConnection huc1 = (HttpURLConnection)UrlConnObj1;
huc1.setRequestMethod("POST");
huc1.setDoOutput(true);
huc1.setDoInput(true);
huc1.setUseCaches(false);
huc1.setDefaultUseCaches(false);
String cadena = ""
+ "<root>\n"
+ "<tlf>$TLF$</tlf>\n"
+ "<op>$OP$</op>\n"
+ "<sc>$SC$</sc>\n"
+ "<body>$BODY$</body>\n"
+ "</root>";
PrintWriter out = new PrintWriter(huc1.getOutputStream());
System.out.println("string="+cadena);
out.write(cadena);
out.close();
I'm a JAVA newbie, so, maybe I'm getting a bad idea of what I need to do, anyway, every (detailed) help is welcome. What my servlet should do (and it doesn't when I send the message through the API) is to write a file with the info received.I'm not trying to send a string from a WEB Page, I'm tryring to send it using a JAVA program, I mean, using a HTTPSender, in fact, I already have made the code to do that:
import java.io.*;
import java.net.*;
public class HTTPSender {
public static void main(String[] args) throws Exception {
try {
String cadena = "Message to be written";
// Send data
URL url = new URL("http://localhost:8080/XMLSender/xmlwriter");
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
wr.write(cadena);
wr.flush();
// Get the response
BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
while ((line = rd.readLine()) != null) {
// Process line...
wr.close();
rd.close();
} catch (Exception e) {
And modified my servlet so it can receive anything:
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import java.sql.*;
public class xmlwriter extends HttpServlet
public void service(HttpServletRequest req, HttpServletResponse res)
throws ServletException, IOException
ServletOutputStream salida = res.getOutputStream();
res.setContentType("text/HTML");
String cadena = req.toString();
File f1 = new File ("c:/salida.xml");
FileWriter out = new FileWriter(f1);
f1.createNewFile();
out.write(cadena);
out.close();
salida.println("OK");
Now the problem is that, the servlet in fact DOES create the file, but....the file is empty, that means that no info is arriving to the servlet, why?, how should I send it then? I repeat FORGET about a Web Page Form, that is in the past and I don't need that. -
How can I send a string like this thru UDP:
0x01 0x40 0x43 0x51
Can I write it like this:
data= 0x01, 0x40, 0x43, 0x51;
Any help, please?InputStream in = null;
HttpURLConnection urlConn = null;
int returnCode = 0;
try {
URL url = new URL(URLEncoder.encode(urlStr));
//Where urlStr is in the form "http://localhost/servlet/myServlet?param1=STRING TO BE PASSED"
//Create the connection to the servlet url
urlConn = (HttpURLConnection)url.openConnection();
urlConn.setDoInput(true);
urlConn.setDoOutput(true);
urlConn.setUseCaches(false);
urlConn.setRequestMethod("GET");
urlConn.setRequestProperty("Accept-Language", "en");
urlConn.setRequestProperty("content-type", "text/xml");
in = urlConn.getInputStream();
//Put code to read return string here
} catch (Exception e) { System.out.println("Error : " + e); }
urlConn.disconnect(); -
How to send query string to OSB Business Service?
Hi
I need to call a Servlet which is accepting http get request.
My system design is
I have a web service interface that I need to expose to Front end application. I am using Proxy service for this.
Then I have a servlet at end system and using Business service to send request to servlet.
I need to pass username, password, jndi context and payload using url encoding.
What all steps do I need to follow for this? How to create query string , which variable I need to play with inbound or outbound?
I have gone through all the answers on this forum but could not understand much.
Thanks
VibhorHii
I am still unable to send http get request to end service.
In flow I have setted $outbound/transport/request-http/query-string too.
But I have to send request with url encoding.
How to encode query string and how can I check whether my request is going correctly or not, is there any variable in which complete url would be stored.
Thanks
Vibhor
Edited by: Vibhor Rastogi on Sep 15, 2010 9:49 AM -
How to send a string to CVI .c and get string return through TestStand sequence?
Hi, I am using TestStand 3.1 and I have the StringConverter.c with CVI 8.0 with the function:
char * string_concat_2 (char* str1,char* str2)
char * str_ret;
str_ret = calloc(200, sizeof(char*));
str_ret = strcat (str_ret, str1);
str_ret = strcat (str_ret, str2);
return str_ret;
I would like to use it through Teststand, so I add a sequence using 'StringValueTest'. I Spectify Module CVI & link to StringConverter.c and type in Function Name: char * string_concat_2 (char* str1,char* str2)
1. How I define to send the string1 ("Hello") & string2 ("World") to the Module?
2. How I define to string return ("HelloWorld" from the Module?
ThanksHi plit string,
You will need to have a parameter passed by reference to return the
string. To do this, use a "C String Buffer" instead of a "C String
(const)" parameter type. There is documentation on this in TestStand
Help. Here is a quote from there:
"When using string parameters, use the C String Buffer or Unicode
String Buffer type if you want the function to be able to change the contents of
the argument in TestStand. Use the C String or Unicode String type if the DLL
function does not modify the argument. You can pass a literal string, a
TestStand string property, or an expression that evaluates to a string as the
value of a string parameter."
Gavin Fox
Systems Software
National Instruments -
How do i create a working Yahoo Messenger icon in my email signature?
I've managed to create working icons for
Email
Twitter
LinkedIn
Maven
But for some reason, Yahoo Messenger doesn't work... Any ideas?
Thanks,
Pete...Leonard,
I used the sample code from StamperUI.cpp as a starting point. I have tried 'LoadBitmap', 'LoadCursor' and 'LoadIcon' and none of these seam to work for me.
As I stated before, I used Visual Studio to create the icons in the resource file, so I would think that they would be recognized by the application.
Thanks,
Gregory -
How to send a string from sender to receiver side using java
I am doing a project on Digital Signature.I have already done with the GUI using java swing.
Now i want to send a string from the sender side to the receiver side on the click of a button using socket programming.
Please can anybody provide me with the code as early as possible.http://catb.org/~esr/faqs/smart-questions.html
-
How to send a string value to a mail_id
Hi everybody
I am trying to send a password to a user mail_id.
I got the password from database as an object value.
so how to convert this object to string type and send to the user Mail_id.
Please help
Message was edited by:
vizcWe retrive the password as string but stored in an object.
So i want to get back once again to string
Object resultObj = null;
try
resultObj = ServiceUtils.verifyQuerry(argList);
// Here we get the password from DB
catch(MoveoException mex)
throw new ServletException(mex.getMessage(),mex);
if(null != resultObj)
CompanyDO companyDO = (CompanyDO) resultObj;
// Here i want print the password
return nextPage;
}How to do this ??? -
How to send query string by using form action
Hai to all,
I am new to this topic Ihave one doubt about jsp form action....
That is I am using input type is submit button
<input type="submit" name="submit" value="Edit" onclick="indows.location.href=+sample.jsp?query=+editvalue+editname">
If I get that queryString in the sample.jsp page it respoce to the null only...... what is the problem to this code ..... please send ur perfect coding as soon as possible. I really waiting for ur replay..........Hai,
I think u can use the "request.getQueryString()" to get the query string instead of using "request.getParameter()".
From the query string value u can get the output.
cheers,
Redrose -
How to send a String value from Servlet to Action class in Struts .
when iam trying to send string value from Servlet to Struts Action class through Http Session, iam getting null value, iam really in big confusion, help me.
please elaborate clearly or put you code of both action and servlet here
Are both of them in same web application -
How to send mail to the yahoo address?...
I try to send the mail to the external address: [email protected]
but the application is error:
nested exception is:
javax.mail.SendFailedException: Invalid Addresses;
nested exception is:
javax.mail.SendFailedException: 553 sorry, that domain isn't in my list of allowed rcpthosts (#5.7.1)
Please help!
Is there any resources about send mail by smtp about JavaMail?
Thanks a lot!take a look at
http://www.palomine.net/qmail/relaying.html
http://www.palomine.net/qmail/selectiverelay.html -
How to restore bookmarks after installing Yahoo Messenger deleted them?
Tried to import from Mozilla program files, gonna uninstall messenger see if that makes a difference...
ThanksBest is to first find and undelete the previous profile folder and then undelete the bookmarkbackups folder in it with the JSON backups (bookmarks-####-##-##.json)
If you can recover an uncorrupted JSON back then you can use it to restore the bookmarks.
*http://kb.mozillazine.org/Backing_up_and_restoring_bookmarks_-_Firefox
*https://support.mozilla.org/kb/Recovering+important+data+from+an+old+profile
*http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox -
How can i send mail to the yahoo mail or gmail or something else
hello guys,
i want to know how to send mails to the yahoo or gmail or something else.i heard that we have to change some smtp address and some port number. can any body suggest me to get that.please help me
any replies will be appreciated greatly.Hi chnaresh,
This is the code I use to send mail, it's not specific to gmail, but it works. The "props" object expects the usual mail properties, "mail.smtp.host", "mail.user" or "mail.smtp.user", as well as "mail.smtp.ssl" which you'd want to set to "true" if you're using gmail. It also expects "mail.smtp.passwd" or "mail.passwd" which my gut tells me is unsafe, but I'm not sure why.
Good luck,
radikal_3dward
public static int sendMail(final Properties props, String subject, String body, String to, String cc, String bcc, String from, File[] attachments, boolean toStdOut)
throws javax.mail.internet.AddressException, javax.mail.MessagingException, javax.mail.NoSuchProviderException
Session sess;
//props.setProperty("mail.debug", "true");
if(props.getProperty("mail.smtp.ssl") != null && props.getProperty("mail.smtp.ssl").equalsIgnoreCase("true"))
Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
String portStr = ((props.getProperty("mail.smtp.port") != null) ? (props.getProperty("mail.smtp.port")) : "465");
props.put("mail.smtp.auth", "true");
props.put("mail.smtp.socketFactory.port", portStr);
props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory");
props.put("mail.smtp.socketFactory.fallback", "false");
sess = Session.getDefaultInstance(props,
new javax.mail.Authenticator()
protected PasswordAuthentication getPasswordAuthentication()
String userName = ((props.getProperty("mail.smtp.user") != null) ? props.getProperty("mail.smtp.user") : props.getProperty("mail.user"));
String passwd = ((props.getProperty("mail.smtp.passwd") != null) ? props.getProperty("mail.smtp.passwd") : props.getProperty("mail.passwd"));
if(userName == null || passwd == null)
return null;
return new PasswordAuthentication(userName , passwd);
else
String portStr = ((props.getProperty("mail.smtp.port") != null) ? (props.getProperty("mail.smtp.port")) : "25");
sess = Session.getInstance(props, null);
//sess.setDebug(true);
MimeMessage mess = new MimeMessage(sess);
mess.setSubject(subject);
StringTokenizer toST = new StringTokenizer(to, ",;");
while(toST.hasMoreTokens())
Address addr = new InternetAddress(toST.nextToken());
mess.addRecipient(Message.RecipientType.TO, addr);
if(from != null)
StringTokenizer fromST = new StringTokenizer(from, ",;");
InternetAddress[] fromAddrs = new InternetAddress[fromST.countTokens()];
for(int i = 0; fromST.hasMoreTokens(); i++)
fromAddrs[i] = new InternetAddress(fromST.nextToken());
mess.addFrom(fromAddrs);
if(cc != null)
StringTokenizer ccST = new StringTokenizer(cc, ",;");
while(ccST.hasMoreTokens())
Address addr = new InternetAddress(ccST.nextToken());
mess.addRecipient(Message.RecipientType.CC, addr);
if(bcc != null)
StringTokenizer bccST = new StringTokenizer(bcc, ",;");
while(bccST.hasMoreTokens())
Address addr = new InternetAddress(bccST.nextToken());
mess.addRecipient(Message.RecipientType.BCC, addr);
BodyPart messageBodyPart = new MimeBodyPart();
Multipart multipart = new MimeMultipart();
if(body != null)
messageBodyPart.setText(body);
multipart.addBodyPart(messageBodyPart);
if(attachments != null)
for(int i = 0; i < attachments.length; i++)
messageBodyPart = new MimeBodyPart();
DataSource source = new FileDataSource(attachments);
messageBodyPart.setDataHandler(new DataHandler(source));
messageBodyPart.setFileName(attachments[i].getName());
multipart.addBodyPart(messageBodyPart);
mess.setContent(multipart);
Address[] allRecips = mess.getAllRecipients();
if(toStdOut)
System.out.println("done.");
//System.out.println("Sending message (\"" + mess.getSubject().substring(0,10) + "...\") to :");
System.out.println("Sending message (\"" + mess.getSubject() + "...\") to :");
for(int i = 0; i < allRecips.length; i++)
System.out.print(allRecips[i] + ";");
System.out.println("...");
Transport.send(mess);
if(toStdOut)
System.out.println("done.");
return 0;
Maybe you are looking for
-
CAN NOT VIEW ALL TABLES IN MY INSTANCE/SCHEMA
neither thru an ODBC connection in Access or thru TOAD can I see all of the tables available to me in my instance. In TOAD I can query them, if i know their names and call them in the SQL but when i go to the table view they are not there.... HELP!!!
-
Non ascii characters being sent from a parameter in a form
Hi! I have seen many topics posted on passing non ascii characters through parameters from one servlet to another and converting them into whatever format is necessary. However, I have not seen anyone answer the following question. I have a jsp page
-
I have a double font suite and both fonts are showing up in the font menu but one of the fonts just displays regular text when typed and not the graphic font that it is supposed to display. The other font displays correctly. Both fonts are in font bo
-
Hi Experts, I have two output types and the output type 2 should only trigger if the output type 1 has processed. we have coded in a routine in transation V/27 , and attached it to output type "ZWMA". As per the logic In the routine we are checkin
-
Buy the same apps again?
Hi. My family has a iTunes account in common, but now i have made my own. Is it possible for me to get the IOS apps and mac apps I bought on the other account. My mom don't want to use them anyway, and we don't want to pay for the same apps over agai