I am not able to execute the transport.send(message)

I am not able to execute the transport.send(message) when trying for sending mail. I am getting error like this : -
javax.mail.SendFailedException: Sending failed;  nested exception is: javax.mail.MessagingException: Could not connect to SMTP host: 10.175.80.50, port: 25;  nested exception is: java.net.ConnectException: Connection timed out: connect
Please help me on this to resolve this issue asap. thanks

Hi Vinod,
public void SendMail( )
    //@@begin SendMail()
          // Specify the host name of the mail server
          String host ="----
          IWDMessageManager messageMgr = wdControllerAPI.getComponent().getMessageManager();
          // Initialize Session
          Properties props = System.getProperties();
          props.put("mail.smtp.host", host);
          props.put("mail.smtp.auth", "true");
          Authenticator auth = new Auth();
          Session session = Session.getInstance(props, auth);
          // Create new MimeMessage
          MimeMessage message = new MimeMessage(session);          
          try
                // Set the From Address
                String from = wdContext.currentContextElement().getCtx_From();
               message.setFrom(new InternetAddress(from));
               //  Set the To Address
               String to = wdContext.currentContextElement().getCtx_To();     
               Address ar[] = new Address[1];
               ar[0] = new InternetAddress(to);
               message.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
               // Set the Subject
               message.setSubject(wdContext.currentContextElement().getCtx_Subject());
               //  Set the Text               
               message.setText(wdContext.currentContextElement().getCtx_Text());            
               Transport tr = session.getTransport("smtp");
               tr.connect("Put again here Host Name", Port Noumber, "userid", "password");               
               tr.sendMessage(message, ar);
          }catch (AuthenticationFailedException e){
               messageMgr.reportException(e.toString(),false);
          }catch (AddressException e)     {
               messageMgr.reportException(e.toString(),false);
          } catch (MessagingException e) {
               messageMgr.reportException(e.toString(),false);
          }catch (Exception e){
               messageMgr.reportException(e.toString(),false);
    //@@end
And also create the class Auth() like
public class Auth extends Authenticator {
     public PasswordAuthentication getPasswordAuthentication()
          String username = "userID";
          String password = "Passwod";     
          return new PasswordAuthentication(username,password);     
Please check it i think i will work. Also please use constant value for the to, from, subject and text.

Similar Messages

  • OAF page is not able to display the custom error messages

    Hi,
    I have extended a seeded CO and trying to throw few custom error messages.
    It was working fine, but suddenly it is not able to display the error messages(but checked that the error messages are still present in application) and saying "Message not found. Application: PER, Message Name: ...."
    Is there any profile option which enables the custom messages?
    Thanks,
    Ranita

    Hi,
    There is no profile to enable the Custom error Messages, u will use the diagnostistics for showing the messages in the custom page
    use the following syntax for writing a msg in Jdeveloper
    pageContext.writeDiagnostics(strClassName, "Initializing the vo....", OAWebBeanConstants.STATEMENT);
    and enable the following profile option to yes
    Fnd:Diagnostics
    Regards
    Chanu

  • Not able to execute the explain plan in development.

    Hi In TOAD when try to click "Explain plan current statement." icon, I getting the below error message. ORA-00604: error occurred at recursive SQL level 1 ORA-01950: no privileges on table space 'DEFAULT_DATA' can anybody give some idea to solve this issue?

    Is this a new user?  You could be running out of quota.
    Ask your DBA to user on that tablespace.
    Alter user <username> quota unlimited on DEFAULT_DATA;
    OR
    Title
    When I do an Explain Plan, I get the error: ORA-00604: error occurred at recursive SQL level 1 OR 
    Description I get the error below when I run / execute an Explain Plan.ORA-00604: error occurred at recursive SQL level 1 ORA-01536: space quota exceeded for tablespace ‘USERS’ (not same but similar)
    Resolution Ensure the Plan Table your Toad is using exists, valid, and can use enough space in the tablespace or give unlimited tablespace rights. Setting Toad to use the PLAN_TABLE from SYS schema via View menu | Toad Options | Oracle | General | Explain Plan can resolve the issue as well.

  • Not able to see the Service Desk Message in "Solution_Manager"

    Hi Gurus,
    Can anyone help me solving my problem,
    We are using Solution Manager 4.0, and want to implement service desk for our systems. I have configured the solution manager service desk and we are able to rise the message from satellite system to solution manager, but i am not able to see those messages in "solution_manager" transaction under service desk in solman, but those messages are reflecting in transaction code "dnotifwl" under "No Processer assigned" option of Personal selection>Notifications Tab.
    Pease guide me to resolve the problem.
    Thanks,
    Krishna.J

    Hi Nico Effenberger ,
    Thanks for ur reply,
    1.have not copied slfn to zslf but modified the entries of slf1 and using directly. When i try to copy either it is copying only the entries or saying Entry zslf does not exists in DNOC_TYPE_NOTIF.
    2. I am having full authorisation sap_all, and sap_new for my system
    3. yes i have created a slfn based on this slf1 messages.
    It will be very helpfull if you could send me any doc related to solman service desk configuration you have done.
    thanks & regards
    Krishna Joish

  • Not able to execute the Method on 64 Bit OS

    Hello All,
    We are compiling the plug-ins for InDesign Server CS3 on XP which has 32 bit Operating system. These plug-ins work fine if the InDesign Server CS3 is also installed on 32 Bit OS.
    But if the InDesign CS3 server is installed on 64bit OS the plug-in method is not invoked also it displays a message as method not found.
    Do we need to compile the plug-in in a specific manner to make it work on 64 Bit OS or it should work as it is.
    Thanks for all the help in advance.
    Regards
    Farzana.

    Hi, 
    Anyone have a solution for this?   I am experiencing the same thing - QC can connect to QTP on VM if I have a remote session open to the VM, but if not I get the error mentioned.
    Also using QTP 11 and QC/ALM 11.

  • Not able to execute the procedure

    Hi everybody,
    I am trying to execute a procedure as below,
    CREATE OR REPLACE procedure test1(n1 IN number, n2 IN number, tot OUT number)
    is
    i number := null;
    begin
    loop
    if n2>n1 then
    i:=i+1;
    tot:=n1+i;
    dbms_output.put_line(tot);
    elsif n2<n1 then
    dbms_output.put_line('Enter a higher value for n2');
    end if;
    end loop;
    end;
    All im trying to do is to print the numbers according to the values we give during the runtime, but doesn't seem to work for me.
    ie.,
    n1=1;
    n2=5;
    tot = 1,2,3,4,5;
    I am sorry if there are some error's in the procedure and would really appreciate if you can help me with this. Thanks in advance for your help.
    Edited by: Pravin on 31 Aug, 2010 2:25 PM

    When i run the procedure now,
    CREATE OR REPLACE procedure test1(n1 IN number, n2 IN number, tot OUT number)
    is
    i number := null;
    begin
    loop
    if n2>n1 then
    i:=i+1;
    tot:=n1+i;
    dbms_output.put_line(tot);
    elsif n2<n1 then
    dbms_output.put_line('Enter a higher value for n1');
    end if;
    exit;
    end loop;
    end;
    set serveroutput on;
    variable tot number;
    execute test1(1,4,:tot);
    print tot;
    Im getting output as,
    PL/SQL procedure successfully completed.
    tot
    Nothing is getting printed now. Any reasons for it. I would like to appreciate everybody's help, by the way. Hope we will find a solution.
    Edited by: Pravin on 31 Aug, 2010 2:40 PM

  • I am not able to execute the following code....Help me ...I am a beginner

    REPORT  YCL_TEST1                               .
    tables : pernr.
    data : pn_begda type p0001-begda,
           pn_endda type p0001-endda.
    infotypes : 0001, 0002, 0006.
    get pernr.
    provide * from p0001
    from p0002 between pn_begda and pn_endda.
    write : p0001-sprps, p0006-locat.
    endprovide.

    Hi
    When you use the Statement <b>get PERNR</b>. This referst to the Logical Database.
    Define the Logical Database in the attributes of your program and you should not face this error.
    Hope this helps and welcome to SDN

  • Not able to get the details of messages in BizTalk Server

    I have Biztalk Server 2010 setup. I have created a sample message and tried to check the application by sending the message(using FILE protocol). I am getting the message at the send port successfully but I can't find any entry in the database for any
    of the message, in any of the tables (InstanceStateMessageReferences_BizTalkServerApplication, Spool, Instances, etc.). I have created receive location and send port on the same server. I want it for monitoring purpose. Am I missing some configuration
    or something else ?

    Hi,
    As stated above if you need to check the message or message properties then you would need to enable tracking, depending on where you want it to be and what you want to track, below are two articles which should help you understand more:
    BizTalk Server: Tracking Data Using BizTalk Admin Console
    BizTalk Server: Checking Tracked Data Using Admin Console
    Maheshkumar
    S Tiwari|User
    Page|Blog|BizTalk
    Server: Multiple XML files to Single FlatFile Using File Adapter

  • Not able to include the system to its transport domain

    Hello,
    We are not able to include the system to its transport domain. We are getting the same error:
    Runtime Errors         SAPSQL_ARRAY_INSERT_DUPREC
    Except.                CX_SY_OPEN_SQL_DB
    Date and Time          01.10.2010 11:27:35
    Please advice
    Sankar

    Hi Shyam,
    This is actually a program error and the same can be rectified by implementing the [SAP NOTE 1412609 - DUPREQ when configuring the transport domain|https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=1412609] using the tcode SNOTE.
    This will resolve ur issue.
    Regards,
    Varadharajan M

  • Not able to see the changes in log

    Hi All,
    I have a question here. Audit log is enabled as well as changes lofs is also enabled in my system ECC 6.0. Suppose i have changed some table entry via SE16, i mean i have updated a table via SE16, but i am not able to track the changes in SM20 or SCU3. the logs only shows that i have executed the transation but there is not any evidence of which table i have updated the entry, Is there any way to find out this in SAP in my scenario?
    Regards,
    Subhash

    Got it, Table was not in Authorization group so it was not showing the data updation information, after assigning the table into Auhtorization group now i am able to see the updated records for that table in SCU3

  • Report exection problem for one user - not able to see the data.

    Hello Friends ,
    Need some help . I have got the one ticket from bussniess side about the report execution .
    Unfortunately , I am also not having authorisation of that report due to sensible data.
    Problem - User is executing the report but some how he is not ABLE TO see the data for one company code Hierachy .
    I executed the same report through RSSMQ via his user id , and I got the  below message.
    All value were selected . Hierachy Authorisation cannot be used.
    A displayed hierachy requier a hierachy authorisation .
    But when i checked his authorisation , I am able to see that he should have authorisation to all the hireachy .
    could you please let me know , how can I check more ?
    Regards,

    after accessing the report , u go to su53 tcode and check the authorization and u can see what is problem in authorization for the that user and u can send the details to secuity team to rectify the issue ,

  • Not able to change the data of test data containers in production system

    Dear All,
    We have created eCATT scripts in Development SolMan System and moved the transports to Production SolMan System.  Customer wants to change the data at Test data containers and run the scripts in production system but we are not able to edit the data. 
    May be the reason is SCC4 transaction code has set the below option.
    Changes and transports for client-specific Objects
    u2022 No changes allowed
    Customer doesnu2019t want to change the above option and wanted to change the test data containers to give different datau2019s and run the eCATT scripts.
    Could you please let me know the solution for this?
    Your help is really appreciated.
    Thanks,
    Mahendra

    eCatt has the feature where you don't need to transport the scripts or test configuration to our target system. We can keep all our scripts and test data in Solman and run this script any other system in your landscape using the System data container and target system.
    Maintain the production as one of the target system in System container in Solman and point that system while running the script. Change the test data in Solman to run this script.
    Let me know if you need more information
    thanks
    Venkat

  • Problem Using HTTP Dispatcher -- Could Not able to get the data in JSP

    Hi, I am using HTTP Dispatcher to send my events to particular URL which is a JSP page. I am trying to populate the received event through URL and populate to a oracle data base. But could not able to get the data in Oracle database.
    Code is :
    <h1>JSP Page</h1>
    <%
    long type = 0;
    String tagId = null;
    String timeStr = "0";
    String deviceName = "";
    // Get Event Parameters
    // Available Parameters: id, siteName, deviceName, data, time, type, subtype, sourceName, correlationId
    try
    type = Long.parseLong(request.getParameter("type")); // Get type
    tagId = request.getParameter("id"); // Get tagId
    timeStr = request.getParameter("time"); // Get time
              deviceName = request.getParameter("deviceName");
    catch (Exception e)
    out.println( "Error: "+e.getMessage() );
              // Write into DB.
              try {
              if ((tagId == null) || (type != 200) ){
                   // Do Nothing
                   //return;
              } else {
                   OracleDataSource ods = new OracleDataSource();
                   String URL = "jdbc:oracle:thin:@//3.235.173.16:1525/vislocal";     
                   ods.setURL(URL);
                   ods.setUser("cus");
                   ods.setPassword("cus");
                   Connection myConn = ods.getConnection();     
                   Statement stmt = myConn.createStatement();
                   String selectQuery =
                             "SELECT MAX(rfid_raw_reads_id) as max_id FROM "+
                        "cus.rfid_raw_reads ";
                   ResultSet rs = stmt.executeQuery(selectQuery);
                   String maxId = "1";
                   if (rs.next()) {
                        maxId = rs.getString(1);               
                   String selectMaxTagIDQuery =
                             "SELECT MAX(rfid_raw_reads_id) as max_id FROM "+
                        "cus.rfid_raw_reads WHERE tag_id = '" + tagId + "'" ;
                   stmt = myConn.createStatement();
                   rs = stmt.executeQuery(selectMaxTagIDQuery);
                   String maxTagId = "1";
                   if (rs.next()) {
                        maxTagId = rs.getString(1);               
                   long primaryKey = 1;
                   long tagKey = 1;
                   try {
                        primaryKey = Long.parseLong(maxId) + 1;
                        tagKey = Long.parseLong(maxTagId) + 1;
                   } catch (Exception e) {
                   long currentTime = System.currentTimeMillis();
                   long updateKey = (tagKey - 1);
                   String updateQuery = " UPDATE cus.rfid_raw_reads SET read_end_time = " + currentTime + " WHERE rfid_raw_reads_id = " + updateKey;
                   Statement updateStmt = myConn.createStatement();
                   updateStmt.execute(updateQuery);     
                   String query =
                        "INSERT INTO cus.rfid_raw_reads (rfid_raw_reads_id, tag_id,device_name,read_start_time) VALUES ("+ primaryKey + ",'" + tagId + "'," + deviceName + "'," + System.currentTimeMillis() + " )" ;
                   Statement insertStmt = myConn.createStatement();
                   insertStmt.execute(query);     
                   myConn.commit();
                   myConn.close();
              } catch (Exception e) {
    %>
    <p>For browser debug:
    <%
    out.println( "Type="+type+" ID="+tagId +" time="+timeStr );
    %>
    Kindly suggest where is the problem...
    Thanks and regards
    Mohammad Nasim Akhtar

    HI Prabhat,
    Thanx for your reply, I worked out and able to receive the data in oracle database, Actually there was some problem in insert Query. Now I have tested the same... and able to edit the same in the Database.....
    But I am facing a new problem, Http Dispatcher in SES console is displaying all the Events generated as well as event in Que but there is no events in the Event Send. I guess it is not able to send the events.....?????
    Event statical is showing like this
    Events Received: 0 (0.00/sec)
    Events Generated: 311 (0.19/sec)
    Events Sent: 2 (0.19/sec)
    Queued Events: 309 (0.19/sec)
    Kindly suggest where is the problem, Is it a JSP problem or OSES end problem.....
    Thanks and regards
    Nasim

  • Not able to get the data in PE51

    Dear Freinds,
                  I have copied similar to the standard in IN01 , in the Pe51> Windows i have kept under W1 all the wage types which comes under earnings and when i execute the payslip   i.e  in the simulation run and when i view the form i can see
    only the wage types but i dont find the correspnding amounts agains each wage type. Please could any one help me
    why iam not able to get the amount agains the wge type?
    regards
    divya.

    Hi,
    I think u might have done some mistakes while configuring PE51 in cumulation ID ..........
    First of all as Siki said check ur master data whether the WT has given in IT 0008 and corresponding amounts entered to the resp WT. if it is ok then check the pe51 config once........
    go to pe51 give ur form name and select cumulation IDs go to change mode and double click on Earnings and see whether the data is maintained in this manner or not .......
    Table = RT ,   ID = your WT code ,    MS = + (sign)   ,  Dsplit = * (sign),      rest all coulumn leave blank ........ save it and then again run the payrl in Live mode and see the Pay slip.........
    If any problem Pls let us know.... and see other gurus post also.
    Regards,
    Prashant

  • Not able to get the connection to mssql server thro native sql

    Dear Experts,
               I have created a database connection to mssql server thro DBCO t.code.Am not able to get the connection when i am executing Native SQl for geting connection of mssql server.
    DATA: CON_NAME LIKE DBCON-CON_NAME VALUE 'BIW'.
    EXEC SQL.
      CONNECT TO :con_name AS 'C1'
    ENDEXEC.
    Am always getting sy-subrc = 4. The user name and password i have given in dbcon table having full authorization to access mssql database. I am working SAP ecc 5.0. Also both servers are running in windows.
    could anyone hlep me on this issue.
    Thanks in advance.

    Hello, the submitted error must be analyzed according to the Syntaxis and characteristics of the MSSQL database. See explanation of error.
    http://doc.ddart.net/mssql/sql2000/html/trblsql/tr_reslsyserr_1_1o1i.htm
    Error 156
    Severity Level 15
    Message Text
    Incorrect syntax near the keyword '%.*ls'.
    Explanation
    This error indicates that the syntax of a Transact-SQL statement is incorrect and that the syntax error was detected near the keyword specified in the error message. The most frequent causes for syntax errors are misspellings of Transact-SQL keywords or operators, and specifying the syntax of a Transact-SQL statement in the wrong order.
    One of the more complicated causes for this error may be a compatibility level mismatch for the current database. If the current database has a compatibility level other than 70, Microsoft® SQL Serveru2122 will not recognize any of the keywords that a database with a compatibility level of 70 would recognize.
    Action
    First, check the Transact-SQL statement syntax near the keyword specified in the error message. Because Transact-SQL language syntax can be very complex, SQL Server may incorrectly report the position of the syntax error as later in the Transact-SQL statement than it actually occurred. Second, reexamine the entire Transact-SQL statement that generated the error. Verify the syntax order of the statement.
    Ensure that the database does not have a compatibility level of 65 and has a compatibility level of 70.

Maybe you are looking for