Problem with RSA3

Hi Guys,
I am trying to Execute RSA3 with 2LIS_05_Q0NOTIF , It is giving the below Short Dump. We have done transports recently and it is ended with Warning RC4.
Runtime Errors         CONNE_IMPORT_WRONG_COMP_TYPE
Exceptn                CX_SY_IMPORT_MISMATCH_ERROR
Date and Time          21.02.2012 15:24:02
ShrtText
     Error when attempting to IMPORT object "MC05Q00NTF_TAB".
What happened?
     Error in ABAP application program.
     The current ABAP program "SAPLMCEX" had to be terminated because one of the
     statements could not be executed.
     This is probably due to an error in the ABAP program.
     When attempting to import data, it was discovered that the data
     type of the stored data was not the same as that specified in the
     program.
What can you do?
     Print out the error message (using the "Print" function)
     and make a note of the actions and input that caused the
     error.
     To resolve the problem, contact your SAP system administrator.
     You can use transaction ST22 (ABAP Dump Analysis) to view and administer
      termination messages, especially those beyond their normal deletion
     date.
     is especially useful if you want to keep a particular message.
Error analysis
     An exception occurred. This exception is dealt with in more detail below
     . The exception, which is assigned to the class 'CX_SY_IMPORT_MISMATCH_ERROR',
      was neither
     caught nor passed along using a RAISING clause, in the procedure
      "MCEX_BW_LO_API" "(FUNCTION)"
     Since the caller of the procedure could not have expected this exception
      to occur, the running program was terminated.
     The reason for the exception is:
     When importing the object "MC05Q00NTF_TAB", the component no. 32 in the
     dataset has a different type from the corresponding component
     of the target object in the program "SAPLMCEX".
Please help any one to resolve the Dump.
Regards
Reddy.

Hi,
Do you have changed the data source structure? Have you deleted the setup table before the import?
=> start transaction LBWG.
=> then fill the setup table again.
before the transport, you have to
- delete the setup table
- and load the delta into the BW (lock your ERP agains changes).
Sven

Similar Messages

  • Problem with RSA3 (0 data records with selection)

    hi,
    I am checking the rsa3 for data source 2lis_11_vaitm.
    i have deleted the setup tables, filled them again..all the stuff.
    when i am checking RSA3 <b>without any selections</b> it is showing some records. and after copying the SD document number from some record
    and trying to make selection on this SD doc num in RSA3 it is not giving any results <b>(0 data records)</b>
    Can some one please let me know whats going wrong.

    Hi
    Giving you 1 example where selection value in RSA3 does not work :-
    If the document number is 10 digit number and what you copied is let's say 88888888 then it is only 8 digits ...hence put leading zeroes to this number and make is 0088888888 and then try this in RSA3 for doc number selection.
    Also ensure that this dociment was present and covered in setup tables job done. Check the setup table log for application 11 in  tcode NPRT
    Regards
    Pradip

  • CO-PA, problem with extractors. (Account Based)

    Hi everybody,
    I have a problem when I want to execute RSA3, on the extractors that automatically generate the systems. I followed all the step that the document say, I belive.
    1.- <KEB0>, I still use mandatory fields PERIO and KOKRS.
    2.- <KEDV>. I put on the all fields a “*” , with exceptions KOKRS. (on it put the variable Controlling Area).
    3.- <KEDU> Summarization levels.
      3.1- Delete an regenerate
      3.2- Refresh. (In this point I show that the systema take very short time, and when check with transactions KEDV, I can see that the refresh records are cero (0).
    4.- Modify on SE11, the tables COEP and COEJ the index 4.
    5.- <RSA3>, finally with the parameters, as example :
    KOKRS: CO01
    PERIO: 2006004,
    The systems show a error.
    I can’t execute the extractors.
    So , I know that is a problem with R3, but I don't use it if I dont want to use BW.
    Some one knows the problems or the other steps that I forget to execute?
    I appreciate your help,
    regards,

    HI,
    To understand, why system behaving like this, you can analyze derivations in KEPM (Extras-> Analyze derivations). Try to enter manually using parameter set and then do Extras->Analyze derivation.
    You could also try chaing the Target fied attributes to 'Overwrite with new value only if new value found' from 'Do no overwrite' in KEDR for your Table look up step.
    Hope this helps.

  • Problems with a table in PDF`S footer

    Dear sirs,
    We are having problems when trying to run a PDF with Adobe LiveCycle Designer tool.
    We are working with a PDF which is composed of a header, the main body and a footer. We have created a table (table1) at the footer and
    another one at the main body (table2). This last table (table2) may overflow therefore it will genarate two pages for our PDF.
    On both pages appear the header and the footer correctly but in the last page it does not write the data from the table included in the footer (table1).
    We have no problems with the table included in the main body
    In the attachments, I send you the screenshots of both pages in which I have marked in red the part where we have error.
    May you help us to solve our problem?
    Thanks in advance your help.
    Edited by: emgaitan on Mar 16, 2010 2:18 PM

    Wardell,
    Check the data in RSA3 for the extractor that you use to bring data .
    You must be using the data source 0CO_OM_CCA_09. Check the data and reconcile and you will get it.
    Let me know if you need anything else.
    Thanks
    Ravi Thothadri
    [email protected]

  • 0CUSTOMER_TEXT - problem with the cyrillic (ukrainian) characters

    Hello,
    Within the framework of Ukrain deployment, I try to extract customer texts (0CUSTOMER_TEXT) and I meet a problem with the cyrillic (ukrainian) characters. All of them are replaced by a '#' (into the table /BI0/TCUSTOMER & into the PSA too).
    From SAP marketplace source, customer text comes from KNA1-NAME1.
    The funniest thing is that the cyrillic (ukrainian) characters extracted by 0CUSTOMER_ATTR are accurately uploaded and specially 0NAME attribute filled by the same r/3 field KNA1-NAME1.
    FYI: I checked the configuration of RFC connections and for all of ABAP connections have the radiobutton UNICODE selected.
    Could someone help me?
    Thanks in advance,
    Samuel

    Hi
    What texts will you get by using T-code: RSA3 in your source system?
    Yaniv

  • Problem with native SQL cursor in generic data source

    Hi, All!
    I am implementing generic data source based on FM.
    Because of complicated SQL I canu2019t use Open SQL and RSAX_BIW_GET_DATA_SIMPLE-example u201Cas isu201D.
    So, I have to use Native SQL. But Iu2019ve got a problem with a cursor. When I test my data source in RSA3, everything is Ok. But, if I start appropriate info-package, I get error u201CABAP/4 processor: DBIF_DSQL2_INVALID_CURSORu201D. It happens after selecting of 1st data package in line u201CFETCH NEXT S1 INTOu2026u201D. It seems to me that when system performs the second call of my FM the opened cursor has already been disappeared.
    Did anyone do things like this and what is incorrect?
    Is it real to make generic data source based on FM with using Native SQL open, fetch, closeu2026

    Hi Jason,
    I don't think this SQL is very valuable It is just an aggregation with some custom rules. This aggregation is performing on info-provider which consists of two info-cubes. Here we have about 2 billion records in info-provider and about 30 million records in custom db-table Z_TMP (certainly, it has indexes). I have to do this operation on 21 info-providers like this and I have to do this 20 times for each info-provider (with different values of host-variable p_GROUP)
    SELECT T.T1, SUM( T.T2 ), SUM( T.T3 ), SUM( T.T4 )
            FROM (
                    SELECT F."KEY_EVENT06088" AS T1,
                            F."/BIC/EV_COST" + F."/BIC/EV_A_COST" AS T2,
                            DECODE( D.SID_EVENTTYPE, 23147, 0,
                                                          23148, 0,
                                                          23151, 0,
                                                          23153, 0,
                                                          23157, 0,
                                                          23159, 0,
                                                          24896734, 0,
                                                          695032768, 0,
                                                          695029006, 0,
                                                          695029007, 0,
                                                          695036746, 0, F."/BIC/EV_COST") +
                              DECODE( D.SID_EVENTTYPE, 23147, 0,
                                                          23148, 0,
                                                          23151, 0,
                                                          23153, 0,
                                                          23157, 0,
                                                          23159, 0,
                                                          24896734, 0,
                                                          695032768, 0,
                                                          695029006, 0,
                                                          695029007, 0,
                                                          695036746, 0, F."/BIC/EV_A_COST") AS T3,
                            DECODE( D.SID_EVENTTYPE, 23147, F."/BIC/EV_DURAT",
                                                          23148, F."/BIC/EV_DURAT",
                                                          23151, F."/BIC/EV_DURAT",
                                                          23153, F."/BIC/EV_DURAT",
                                                          23157, F."/BIC/EV_DURAT",
                                                          23159, F."/BIC/EV_DURAT",
                                                          24896734, F."/BIC/EV_DURAT",
                                                          695032768, F."/BIC/EV_DURAT",
                                                          695029006, F."/BIC/EV_DURAT",
                                                          695029007, F."/BIC/EV_DURAT",
                                                          695036746, F."/BIC/EV_DURAT", 0) AS T4
                      FROM "/BIC/VEVENT0608F" F,
                           Z_TMP G,
                           "/BIC/DEVENT06085" D
                      WHERE F."KEY_EVENT06088" = G.ID
                            AND F."KEY_EVENT06085" = D.DIMID
                            AND G.GROUP_NO = :p_GROUP
                            AND ( F."/BIC/EV_COST" < 0 OR F."/BIC/EV_A_COST" < 0 )
                            AND D.SID_EVENTTYPE <> 695030676 AND D.SID_EVENTTYPE <> 695030678
                    UNION
                    SELECT F."KEY_EVNA06088" AS T1,
                            F."/BIC/EV_COST" + F."/BIC/EV_A_COST" AS T2,
                            DECODE( D.SID_EVENTTYPE, 23147, 0,
                                                          23148, 0,
                                                          23151, 0,
                                                          23153, 0,
                                                          23157, 0,
                                                          23159, 0,
                                                          24896734, 0,
                                                          695032768, 0,
                                                          695029006, 0,
                                                          695029007, 0,
                                                          695036746, 0, F."/BIC/EV_COST") +
                              DECODE( D.SID_EVENTTYPE, 23147, 0,
                                                          23148, 0,
                                                          23151, 0,
                                                          23153, 0,
                                                          23157, 0,
                                                          23159, 0,
                                                          24896734, 0,
                                                          695032768, 0,
                                                          695029006, 0,
                                                          695029007, 0,
                                                          695036746, 0, F."/BIC/EV_A_COST") AS T3,
                            DECODE( D.SID_EVENTTYPE, 23147, F."/BIC/EV_DURAT",
                                                          23148, F."/BIC/EV_DURAT",
                                                          23151, F."/BIC/EV_DURAT",
                                                          23153, F."/BIC/EV_DURAT",
                                                          23157, F."/BIC/EV_DURAT",
                                                          23159, F."/BIC/EV_DURAT",
                                                          24896734, F."/BIC/EV_DURAT",
                                                          695032768, F."/BIC/EV_DURAT",
                                                          695029006, F."/BIC/EV_DURAT",
                                                          695029007, F."/BIC/EV_DURAT",
                                                          695036746, F."/BIC/EV_DURAT", 0) AS T4
                    FROM "/BIC/VEVNA0608F" F,
                         Z_TMP G,
                         "/BIC/DEVNA06085" D
                    WHERE F."KEY_EVNA06088" = G.ID
                          AND F."KEY_EVNA06085" = D.DIMID
                          AND G.GROUP_NO = :p_GROUP
                          AND ( F."/BIC/EV_COST" < 0 OR F."/BIC/EV_A_COST" < 0 )
                          AND D.SID_EVENTTYPE <> 695030676 AND D.SID_EVENTTYPE <> 695030678
                 ) T
            GROUP BY T.T1

  • Function module based generic extractor - Problem with the selection

    Hi all
    The following is my code in the function module. I am able to get the entire data if i dont give any selections and the number of records is also correct. But when i select a MATNR value, it returns 0 records where as it needs to return 3 records. If i give selection based on bukrs, werks, lgort its working fine. But if i give selection based on MATNR, then it is not working.... I think there is a problem in the bold part of my code. If i debug, LS_MATNR is having the correct value which indicates that there is no problem with the value being passed to LS_MATNR from my selection screen of my datasource in RSA3. Even GT_WERKS is also having data. Please help.
    OPEN CURSOR WITH HOLD S_CURSOR FOR
    SELECT  MARA~MANDT
            MARA~MATNR
            MARC~WERKS
            MARD~LGORT
            MARA~MEINS
            MARD~LABST
            MARD~EINME
            MARD~SPEME
            MARD~RETME
            MARD~INSME
            MARD~UMLME
            MARD~VMLAB
            MARD~VMEIN
            MARD~VMSPE
            MARD~VMRET
            MARD~VMINS
            MARD~VMUML
            MARC~XCHPF
            MARD~KLABS
            MARD~KEINM
            MARD~KSPEM
            MARD~KINSM
    from MARA inner join MARC on
    MARAMANDT = MARCMANDT AND
    MARAMATNR = MARCMATNR
    inner join MARD on
    MARAMANDT = MARDMANDT AND
    MARAMATNR = MARDMATNR
    AND MARCWERKS = MARDWERKS
    for all entries in gt_werks
    where MARC~werks EQ gt_werks-werks
    AND MARA~MATNR in LS_MATNR.
        ENDIF.                             "First data package ?
    Fetch records into interface table.
      named E_T_'Name of extract structure'.
        FETCH NEXT CURSOR S_CURSOR
                   APPENDING CORRESPONDING FIELDS
                   OF TABLE E_T_DATA
                   PACKAGE SIZE S_S_IF-MAXSIZE.

    try this
    select marc~matnr MARC~WERKS into t_marc for all entries in gt_werks
    where werks EQ gt_werks-werks and lvorm = space.
    if t_marc is not initial.
    select MARD~LGORT MARD~WERKS MARA~MEINS MARD~LABST MARD~EINME
    MARD~SPEME MARD~RETME MARD~INSME MARD~UMLME
    MARD~VMLAB MARD~VMEIN MARD~VMSPE MARD~VMRET
    MARD~VMINS MARD~VMUML MARC~XCHPF MARD~KLABS
    MARD~KEINM MARD~KSPEM MARD~KINSM  MARA~MEINS  from
    mard inner join MARA on mard~matnr = mara~matnr
    for all entries in t_marc where  mard~matnr = t_marc-matnr and mard-werks = t_marc-matnr
    and mard~lvorm = space.

  • Problem with extractors after system copy

    Hi Gurus!
    After system copy I have problem with export data source from infocubes. Logical system name was converted  with BDLS. When I check any export datasource (8*) with transaction RSA3 system tell me that no data records was found though data in fact table every infocube exist (in SE11). What can I do to solve this problem?
    Thanx.

    Hi,
    Of course I tried reactivate myself source system but problem is still here. When I check extractor (with RSA3) of any data source of  any infoobject (master data) - everything is OK. When I check extractor for export data sorce - I have problem.
    to Mickael: In modeling every thing is OK.
    Thank you for all answers.....

  • Problems with the load of Deliveries

    Hi experts,
    I am having some problems with the load of Deliveries from R/3 into BW.
    In LIPS table of R/3, there are 41412 records. I delete the setup tables and realize the extraction with the transaction OLI8BW. After that I launch a simulation with RSA3 but only 6765 records are taken into account.
    Apart of that, there is a range of deliveries documents (between 180000000 and 1084000000) that is not be taken into account.
    Has someone have similar problems with the load of deliveries?
    Thanks.

    Matute,
       you can try comparing those missing records with those already extracted. I found in my side that some records with document category of "H"(Returns) don't be extracted by 2lis_12_vcitm.
    Jin Ming

  • Problems with Delta Extraction for 0CRM_OPPT_H (no data found)

    Hi,
    I've some problems with the Delta Extraction of the Infosource 0crm_oppt_h (CRM Opportunities Header). After initialization I get no delta data from the CRM system.
    What I already did:
    Activated 0crm_oppt_h Data Source (checked functionality with rsa3)
    Started Info Package (Init) on BW side (worked fine)
    Checked the status of the Data Source on the CRM system using BWA7 ("initial upload" is unmarked; "delta active" is marked and what makes me worry is that the column "Queue exists" in <i>unmarked</i>...)
    If I change anything (like Phase, Expected Sales Vol.) in the opportunity, the Delta Extraction get no changes.
    Could You help me out, please?
    Best regards,
    Markus Svec

    hi Markus,
    try to check oss note 788172
    Release Status Released for Customer
    Released on 23.03.2005
    Priority Correction with high priority
    Category Program error
    Symptom
    No data exists in delta extraction from the CRM server to the BW system for business transactions, if parallel processing is applied as per note 639072. But Data is extracted if parallel processing is switched off.ie. when BWA_NUMBER_OFF_PROCESSES is set to 1,there is data during delta. This applies to the following DataSources:
    0BBP_TD_CONTR_1
    0CRM_COMPLAINTS_I
    0CRM_LEAD_ATTR
    0CRM_LEAD_H
    0CRM_LEAD_I
    0CRM_OPPT_ATTR
    0CRM_OPPT_H
    0CRM_OPP T_I
    0CRM_QUOTATION_I
    0CRM_QUOTA_ORDER_I
    0CRM_SALES_ACT_1
    0CRM_SALES_CONTR_I
    0CRM_SALES_ORDER_I
    0CRM_SRV_CODES
    0 CRM_SRV_CONFIRM_H
    0CRM_SRV_CONFIRM_I
    0CRM_SRV_CONTRACT_H
    0CRM_SRV_PROCESS_H
    0CRM_SRV_PROCESS_I
    Other terms
    DataSources, BWA, initial extraction, delta init, parallel processing, no data in delta.
    Reason and Prerequisites
    There is an update on the generated delta table which causes data corruption in running delta initializations as the changed delta sets will be deleted with every further update on documents. An open cursor statement is there without fetch data in SMOX3_GET_DATA.
    Solution
    The problem is solved with the attached corrections.After applying the corrections a new initialization of the affected datasources is necessary.

  • A problem with 1CL_OLIS002 and 1CL_OMAT001 extractors - delta extraction

    Hi
    I have a problem with 1CL_OLIS002 and 1CL_OMAT001 extractors - delta extraction.
    Interrelated extractors: 2LIS_11_VAITM and ZMATBATCH_Attr work well.
    For 1CL's extractors I see current data in RSA3 but I don't see LUWs in RSA7.
    Extractors send 0 records to BW.
    There is no entry in "BIREQU* " job logs like this:
    "Call customer enhancement BW_BTE_CALL_BW204010_E (BTE) with xxx records".
    which I find in job logs when all worked well.
    We had some problems with R3. I had to restart job "LIS-BW-VB-APPLICATION_13*".
    May be it has influence on these extractors?
    Any suggestions about how to resolve the problem?
    Regards
    PWnuk

    Hi
    Can you please share the solution of this problem with me,I am also facing same issue of Delta not working but full load is working in 1CL_OBI_001?
    Edited by: Aseem84 on Jan 12, 2011 10:23 AM

  • A problem with threads

    I am trying to implement some kind of a server listening for requests. The listener part of the app, is a daemon thread that listens for connections and instantiates a handling daemon thread once it gets some. However, my problem is that i must be able to kill the listening thread at the user's will (say via a sto button). I have done this via the Sun's proposed way, by testing a boolean flag in the loop, which is set to false when i wish to kill the thread. The problem with this thing is the following...
    Once the thread starts excecuting, it will test the flag, find it true and enter the loop. At some point it will LOCK on the server socket waiting for connection. Unless some client actually connects, it will keep on listening indefinatelly whithought ever bothering to check for the flag again (no matter how many times you set the damn thing to false).
    My question is this: Is there any real, non-theoretical, applied way to stop thread in java safely?
    Thank you in advance,
    Lefty

    This was one solution from the socket programming forum, have you tried this??
    public Thread MyThread extends Thread{
         boolean active = true;          
         public void run(){
              ss.setSoTimeout(90);               
              while (active){                   
                   try{                       
                        serverSocket = ss.accept();
                   catch (SocketTimeoutException ste){
                   // do nothing                   
         // interrupt thread           
         public void deactivate(){               
              active = false;
              // you gotta sleep for a time longer than the               
              // accept() timeout to make sure that timeout is finished.               
              try{
                   sleep(91);               
              }catch (InterruptedException ie){            
              interrupt();
    }

  • Problem with Threads and a static variable

    I have a problem with the code below. I am yet to make sure that I understand the problem. Correct me if I am wrong please.
    Code functionality:
    A timer calls SetState every second. It sets the state and sets boolean variable "changed" to true. Then notifies a main process thread to check if the state changed to send a message.
    The problem as far I understand is:
    Assume the timer Thread calls SetState twice before the main process Thread runs. As a result, "changed" is set to true twice. However, since the main process is blocked twice during the two calls to SetState, when it runs it would have the two SetState timer threads blocked on its synchronized body. It will pass the first one, send the message and set "changed" to false since it was true. Now, it will pass the second thread, but here is the problem, "changed" is already set to false. As a result, it won't send the message even though it is supposed to.
    Would you please let me know if my understanding is correct? If so, what would you propose to resolve the problem? Should I call wait some other or should I notify in a different way?
    Thanks,
    B.D.
    Code:
    private static volatile boolean bChanged = false;
    private static Thread objMainProcess;
       protected static void Init(){
            objMainProcess = new Thread() {
                public void run() {
                    while( objMainProcess == Thread.currentThread() ) {
                       GetState();
            objMainProcess.setDaemon( true );
            objMainProcess.start();
        public static void initStatusTimer(){
            if(objTimer == null)
                 objTimer = new javax.swing.Timer( 1000, new java.awt.event.ActionListener(){
                    public void actionPerformed( java.awt.event.ActionEvent evt){
                              SetState();
        private static void SetState(){
            if( objMainProcess == null ) return;
            synchronized( objMainProcess ) {
                bChanged = true;
                try{
                    objMainProcess.notify();
                }catch( IllegalMonitorStateException e ) {}
        private static boolean GetState() {
            if( objMainProcess == null ) return false;
            synchronized( objMainProcess ) {
                if( bChanged) {
                    SendMessage();
                    bChanged = false;
                    return true;
                try {
                    objMainProcess.wait();
                }catch( InterruptedException e ) {}
                return false;
        }

    Thanks DrClap for your reply. Everything you said is right. It is not easy to make them alternate since SetState() could be called from different places where the state could be anything else but a status message. Like a GREETING message for example. It is a handshaking message but not a status message.
    Again as you said, There is a reason I can't call sendMessage() inside setState().
    The only way I was able to do it is by having a counter of the number of notifies that have been called. Every time notify() is called a counter is incremented. Now instead of just checking if "changed" flag is true, I also check if notify counter is greater than zero. If both true, I send the message. If "changed" flag is false, I check again if the notify counter is greater than zero, I send the message. This way it works, but it is kind of a patch than a good design fix. I am yet to find a good solution.
    Thanks,
    B.D.

  • Problem with threads running javaw

    Hi,
    Having a problem with multi thread programming using client server sockets. The program works find when starting the the application in a console using java muti.java , but when using javaw multi.java the program doesnt die and have to kill it in the task manager. The program doesnt display any of my gui error messages either when the server disconnect the client. all works find in a console. any advice on this as I havent been able to understand why this is happening? any comment would be appreciated.
    troy.

    troy,
    Try and post a minimum code sample of your app which
    does not work.
    When using javaw, make sure you redirect the standard
    error and standard output streams to file.
    Graeme.Hi Graeme,
    I dont understand what you mean by redirection to file? some of my code below.
    The code works fine under a console, code is supposed to exit when the client (the other server )disconnects. the problem is that but the clientworker side of the code still works. which under console it doesnt.
    public class Server{
    ServerSocket aServerSocket;
    Socket dianosticsSocket;
    Socket nPortExpress;
    ClientListener aClientListener;
    LinkedList queue = new LinkedList();
    int port = 0;
    int clientPort = 0;
    String clientName = null;
    boolean serverAlive = true;
    * Server constructor generates a server
    * Socket and then starts a client threads.
    * @param aPort      socket port of local machine.
    public Server(int aPort, String aClientName, int aClientPort){
    port = aPort;
    clientName = aClientName;
    clientPort = aClientPort;
    try{
    // create a new thread
    aServerSocket = new ServerSocket(port) ;
    // connect to the nPortExpress
    aClientListener = new ClientListener(InetAddress.getByName(clientName), clientPort, queue,this);
    // aClientListener.setDaemon(true);
    aClientListener.start();
    // start a dianostic port
    DiagnosticsServer aDiagnosticsServer = new DiagnosticsServer(port,queue,aClientListener);
    // System.out.println("Server is running on port " + port + "...");
    // System.out.println("Connect to nPort");
    catch(Exception e)
    // System.out.println("ERROR: Server port " + port + " not available");
    JOptionPane.showMessageDialog(null, (e.toString()),"ERROR: Server port " + port + " not available", JOptionPane.ERROR_MESSAGE);
    serverAlive = false;
    System.exit(1);
    while(serverAlive&&aClientListener.hostSocket.isConnected()){
    try{
    // connect the client
    Socket aClient = aServerSocket.accept();
    //System.out.println("open client connection");
    //System.out.println("client local: "+ aClient.getLocalAddress().toString());
    // System.out.println("client localport: "+ aClient.getLocalPort());
    // System.out.println("client : "+ aClient.getInetAddress().toString());
    // System.out.println("client port: "+ aClient.getLocalPort());
    // make a new client thread
    ClientWorker clientThread = new ClientWorker(aClient, queue, aClientListener, false);
    // start thread
    clientThread.start();
    catch(Exception e)
    //System.out.println("ERROR: Client connection failure");
    JOptionPane.showMessageDialog(null, (e.toString()),"ERROR: Client connection failure", JOptionPane.ERROR_MESSAGE);
    }// end while
    } // end constructor Server
    void serverExit(){
         JOptionPane.showMessageDialog(null, "Server ","ERROR: nPort Failure", JOptionPane.ERROR_MESSAGE);
         System.exit(1);
    }// end class Server
    *** connect to another server
    public class ClientListener extends Thread{
    InetAddress hostName;
    int hostPort;
    Socket hostSocket;
    BufferedReader in;
    PrintWriter out;
    boolean loggedIn;
    LinkedList queue;      // reference to Server queue
    Server serverRef; // reference to main server
    * ClientListener connects to the host server.
    * @param aHostName is the name of the host eg server name or IP address.
    * @param aHostPort is a port number of the host.
    * @param aLoginName is the users login name.
    public ClientListener(InetAddress aHostName, int aHostPort,LinkedList aQueue,Server aServer)      // reference to Server queue)
    hostName = aHostName;
    hostPort = aHostPort;
    queue = aQueue;
    serverRef = aServer;      
    // connect to the server
    try{
    hostSocket = new Socket(hostName, hostPort);
    catch(IOException e){
    //System.out.println("ERROR: Connection Host Failed");
    JOptionPane.showMessageDialog(null, (e.toString()),"ERROR: Connection to nPort Failed", JOptionPane.ERROR_MESSAGE);     
    System.exit(0);
    } // end constructor ClientListener
    ** multi client connection server
    ClientWorker(Socket aSocket,LinkedList aQueue, ClientListener aClientListener, boolean diagnostics){
    queue = aQueue;
    addToQueue(this);
    client = aSocket;
    clientRef = aClientListener;
    aDiagnostic = diagnostics;
    } // end constructor ClientWorker
    * run method is the main loop of the server program
    * in change of handle new client connection as well
    * as handle all messages and errors.
    public void run(){
    boolean alive = true;
    String aSubString = "";
    in = null;
    out = null;
    loginName = "";
    loggedIn = false;
    while (alive && client.isConnected()&& clientRef.hostSocket.isConnected()){
    try{
    in = new BufferedReader(new InputStreamReader(client.getInputStream()));
    out = new PrintWriter(new OutputStreamWriter(client.getOutputStream()));
    if(aDiagnostic){
    out.println("WELCOME to diagnostics");
    broadCastDia("Connect : diagnostics "+client.getInetAddress().toString());
    out.flush();
    else {       
    out.println("WELCOME to Troy's Server");
    broadCastDia("Connect : client "+client.getInetAddress().toString());
         out.flush();
    String line;
    while(((line = in.readLine())!= null)){
    StringTokenizer aStringToken = new StringTokenizer(line, " ");
    if(!aDiagnostic){
    broadCastDia(line);
    clientRef.sendMessage(line); // send mesage out to netExpress
    out.println(line);
    out.flush();
    else{
    if(line.equals("GETIPS"))
    getIPs();
    else{
    clientRef.sendMessage(line); // send mesage out to netExpress
    out.println(line);
    out.flush();
    } // end while
    catch(Exception e){
    // System.out.println("ERROR:Client Connection reset");
                             JOptionPane.showMessageDialog(null, (e.toString()),"ERROR:Client Connection reset", JOptionPane.ERROR_MESSAGE);     
    try{
    if(aDiagnostic){
    broadCastDia("Disconnect : diagnostics "+client.getInetAddress().toString());
    out.flush();
    else {       
    broadCastDia("Disconnect : client "+client.getInetAddress().toString());
         out.flush();
    // close the buffers and connection;
    in.close();
    out.close();
    client.close();
    // System.out.println("out");
    // remove from list
    removeThreadQueue(this);
    alive = false;
    catch(Exception e){
    // System.out.println("ERROR: Client Connection reset failure");
    JOptionPane.showMessageDialog(null, (e.toString()),"ERROR: Client Connection reset failure", JOptionPane.ERROR_MESSAGE);     
    }// end while
    } // end method run
    * method run - Generates io stream for communicating with the server and
    * starts the client gui. Run also parses the input commands from the server.
    public void run(){
    boolean alive = true;
    try{
    // begin to life the gui
    // aGuiClient = new ClientGui(hostName.getHostName(), hostPort, loginName, this);
    // aGuiClient.show();
    in = new BufferedReader(new InputStreamReader(hostSocket.getInputStream()));
    out = new PrintWriter(new OutputStreamWriter(hostSocket.getOutputStream()));
    while (alive && hostSocket.isConnected()){
    String line;
    while(((line = in.readLine())!= null)){
    System.out.println(line);
    broadCast(line);
    } // end while
    } // end while
    catch(Exception e){
    //     System.out.println("ERRORa Connection to host reset");
    JOptionPane.showMessageDialog(null, (e.toString()),"ERROR: Connection to nPort reset", JOptionPane.ERROR_MESSAGE);
    try{
    hostSocket.close();
         }catch(Exception a){
         JOptionPane.showMessageDialog(null, (a.toString()),"ERROR: Exception", JOptionPane.ERROR_MESSAGE);
    alive = false;
    System.exit(1);
    } // end method run

  • Problem with threads and camera.

    Hi everybody!
    I've a problem with taking snapshot.
    I would like to display a loading screen after it take snapshot ( sometimes i
    have to wait few seconds after i took snapshot. Propably photo is being taken in time where i have to wait).
    I was trying to use threads but i didn't succeed.
    I made this code:
    display.setCurrent(perform);               
            new Thread(new Runnable(){
                public void run() {               
                    while((!performing.isShown()) && (backgroundCamera.isShown())){
                        Thread.yield();
                    notifyAll();
            }).start();
            new Thread(new Runnable(){
                public void run() {
                    try {
                        this.wait();                   
                    } catch(Exception e) {
                        exceptionHandler(e);
                    photo = camera.snapshot();                               
                    display.setCurrent(displayPhoto);
            }).start();This code is sometimes showing performing screen but sometimes no.
    I don't know why. In my opinion performing.isShown() method isn't working correctly.
    Does anyone have some idea how to use threads here?

    Hi,
    I've finally managed to work this fine.
    The code:
           Object o = new Object();
           display.setCurrent(perform);               
            new Thread(new Runnable(){
                public void run() {               
                    while(!performing.isShown()){
                        Thread.yield();
                   synchronized(o) {
                      o.notify();
            }).start();
            new Thread(new Runnable(){
                public void run() {
                    try {
                        synchronized(o) {
                           o.wait(1);
                    } catch(Exception e) {
                        exceptionHandler(e);
                    photo = camera.snapshot();                               
                    display.setCurrent(displayPhoto);
            }).start();

Maybe you are looking for

  • Errors in Business Rules

    Hi, I am working on Capital Budget in Planning. I created some forms and enter datas into it. While launching the Business rules for that form *"Exisiting Asset"*, I am getting the wrong variables, Instead of "*Asset class variable*" it showing the "

  • CR4E     ....   you know someone who works  this plugin with MS ACCESS??

    Post Author: arfetgas CA Forum: Data Connectivity and SQL !SESSION 2008-04-09 10:22:33.775 - eclipse.buildId=M20071023-1652 java.version=1.6.0_05 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=es_ES Command-l

  • Installing Nokia Maps on N95

    Hi, trying to install the program "Nokia Maps" on my new N95, but it keeps failing. Have tried both from PC and from putting the file "Nokia_Maps_S60.SISX" on the Memory card and starting from there. It get s through "Install smart2go?" but then stop

  • EBS on check no.

    Hi, First, I have populated check no. in assignment fied of outfoing payment document, using T Code: FCHU. I received below MT940 statement from bank, where in we can find the check nos.: :61:1004240424D900,00NCLRNONREF//02-3Y-00032965 :61:1004240424

  • When downloading it says it will continue when windows messenger is closed.  It's not open? help!

    When I tried to download, it said it would continue when windows messenger is closed, but it is not open and I don't know what to do now.  Can anyone help?