Home     |     Java    |     Php General    |     Oracle Database    |     Oracle Server  

MS Dynamics CRM 3.0

  •  Setting up and Configuring Microsoft Dynamics CRM 3.0
  •  Managing Security and Information Access
  •  Entity Customization: Concepts and Attributes
  •  Entity Customization: Forms and Views
  •  Entity Customization: Relationships, Custom Entities, and Site Map
  •  Reporting and Analysis
  •  Workflow
  •  Server-Side SDK
  •  Client-Side SDK
  •  Integration with External Applications
  • Cervo Technologies
    The Right Source to Outsource

    Sharepoint Portal Server KB

    Microsoft CRM Info

    WPF Interview Questions

    SilverLight Interview Qs

    Asp.Net 2.0 Interview Qs

    Asp.NET 1.1 FAQs

    Oracle Interview Questions

    SAP Interview Questions

    Java Programming

    PROBLEM WITH TOMCAT APPLICATION AND SESSIONS LISTENERS


    HI MY PROBLEM IS THAT I'VE THIS CODE:
    package listeners;

    import java.io.IOException;
    import java.util.Vector;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import javax.servlet.http.HttpSession;

    import javax.servlet.http.HttpSession;
    import javax.servlet.http.HttpSessionAttributeListener;
    import javax.servlet.http.HttpSessionBindingEvent;

    public class objetoEscuchadoDeSesion implements
    HttpSessionAttributeListener {
      private String id, name, value, source, message = new String();
      private HttpSession session = null;

      /** Creates new SessionAttribListen */
      public objetoEscuchadoDeSesion() {
        System.out.println(getClass().getName());
      }

      public void attributeAdded(HttpSessionBindingEvent se) {
        session = se.getSession();
        id = session.getId();
        name = se.getName();
        value = (String) se.getValue();
        source = se.getSource().getClass().getName();
        message = new StringBuffer("Attribute bound to session in ")
            .append(source).append("\nThe attribute name: ").append(name)
            .append("\n").append("The attribute value:").append(value)
            .append("\n").append("The session ID:
    ").append(id).toString();
        System.out.println(message);
      }

      public void attributeRemoved(HttpSessionBindingEvent se) {
        session = se.getSession();
        id = session.getId();
        name = se.getName();
        if (name == null)
          name = "Unknown";
        value = (String) se.getValue();
        source = se.getSource().getClass().getName();
        message = new StringBuffer("Attribute unbound from session in ")
            .append(source).append("\nThe attribute name: ").append(name)
            .append("\n").append("The attribute value: ").append(value)
            .append("\n").append("The session ID:
    ").append(id).toString();
        System.out.println(message);
      }

      public void attributeReplaced(HttpSessionBindingEvent se) {
        source = se.getSource().getClass().getName();
        message = new StringBuffer("Attribute replaced in session  ")
            .append(source).toString();
        System.out.println(message);
      }

      public String toString() {
           return " Tiempo de Entrada: "+ new java.util.Date()+
           ", User: "+this.name+" = "+this.value;
        }

    }

    HI, I'D PROBED THIS CODE AND IT WORKS, OK, BUT IF I WANT TO SHOW THE
    OBJECT SESSION TO AN ADMINISTRATOR WHO HAS BEEN LOGIN TO MY
    APPLICATION LIKE THIS:
    HI user_name | you are [admin] IN this app | these are all THE USERS
    CONECTED RIGTH NOW ->omm79/ADMIN
                                         ->jlmm  /user
                                         ->bebo  /user
    I'M TRIYING TO DO SOMETHIG BUT ALL I GOT IS JUST WATCH THE SESSION
    INFO IN THE SERVER SIDE COMMAND-WINDOW, AND IN THE APPLICATION WINDOW
    SHOW THE FIELDS IN NULL LIKE THIS:

    welcome omm79
    Users: Fri May 11 16:35:05 CDT 2007, User: null = null

    , AND I'LL APRETIATE IF THERE IS AN EXAMPLE TO CHECK, THANKS.

    Add to del.icio.us | Digg this | Stumble it | Powered by Megasolutions Inc