Replacement OF comm.jar

Hi Everybody
Sun is removed the link to download comm.jar from its site. This mean there should be some alternative library to connect to COM port.
I am trying to send SMS from my PC using GSM modem. All the code sample I found over the net is using the comm API. Which is I thought depreciated.
Please tell if comm.jar is the only solution or there is other way to do this
Thank You
Sr. Software Engineer
Syed Saifuddin

I had bizzare problems with this too. I am using win2000. My solution was to put comm.jar and javax.comm.properties in c:\opt\comm These are the only files in this directory. I found that I could not open a comm port if 1) I had the files on a different drive 2) the directory path contained directory names with more than 8 characters.
Hope that helps.

Similar Messages

  • Calculated formula for replacing a comma with a Semicolon in a text field

    I need help replacing a comma with a Semicolon in a text field.
    I have a field that has names separated by commas.  
    Ex: Dog, Cat, Bird, Horse, Eagle, Worm, Snake
    I would like a calculated column that converts the field into: Dog; Cat; Bird; Horse; Eagle; Worm; Snake
    I figured out the first three positions (Dog, Cat, Bird,) but I can't figure out the rest.
    Using the formula below.
    =REPLACE((REPLACE((REPLACE([Title],SEARCH(",",[Title]),"1"," ; ")),SEARCH(",",(REPLACE([Title],SEARCH(",",[Title]),"1"," ; "))),"1"," ; ")),SEARCH(",",(REPLACE((REPLACE([Title],SEARCH(",",[Title]),"1","
    ; ")),SEARCH(",",(REPLACE([Title],SEARCH(",",[Title]),"1"," ; "))),"1"," ; "))),"1"," ; ")
    Please help

    check the similar post
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/66e2ae2a-4da9-4c58-a8bb-cf46b1bf448f/calculated-column-to-replace-commas?forum=sharepointgenerallegacy

  • Using comm.jar

    I'm trying to use serial port to configure a device. I've installed the javacomm20-win32, and copied the comm.jar and javax.comm.properties file in c:\j2sdk1.4.2_04\lib and the win32com.dll in c:\j2sdk1.4.2_04\bin and then added comm.jar to my classpath in Netbeans. The problem is the serialdemo example included in javacomm20-win32.zip doesn't work because it can't find any port. It seems like javax.comm.properties is not installed but it is ! I don't know where's the problem, I would appreciate any help.
    Thank you in advance.

    I got the same problem !!!
    HELOW,
    IS ANYBODY IN THERE? (Pink Floyd)
    Sun people: Could you help us here please?
    I know it's hard to answer the same answer doezens of times. At least guide us to a doc or URL...
    bye

  • Does comm.jar can only be used in jdk 1.3.1 ?

    Does this comm.jar be used in jdk1.3.1 only ?
    If I try to run my program from D: whereas my jdk1.3.1 and comm.jar is in C:, I faced exception such as nullPointerExeception. can anyone tell me why ?
    Thank you.

    comm.jar must be installed on the JRE\EXT directory on your computer, and the property file on the lib directory. It doesn't (or shouldn't?) matter if your application is on another drive. The DLL for your OS must be accesible to the system (via PATH in Windows, LIBPATH in OS/2, etc).
    As the jar is on the EXT dir, you do not have to include it in the classpath.

  • Do we have a new version of comm.jar?

    The version I am using in Windows is 1.0, jared in 1998. I am wondering if there is any new comm.jar release for Windows. I can find comm 3.0 for Linux in Sun site but nothing about Windows. Does anyone have info on it? What is Sun's plan on this package for Windows? Thanks!

    Sun's plan is: "scrap it and never touch it again" as MS changed the API. Look for an alternate implementation like RXTX.

  • Replace last comma with ' and '

    Hi All,
    please let me know is there any simple way of replacing last comma in as string with ' and '
    eg: 1.  abc,xyz,wuv should be returned abc,xyz and wuv
         2. abc,wuv should be returned abc and wuv
         3. abc,pqr,cuq,wuv should be returned abc ,pqr,cuq and wuv
    DB version : 11.2.0.3
    Thanks,
    DS

    With only SUBSTR and INSTR:
    <LQS with sample_data as ( select 'abc,xyz,wuv' str  from dual union
      2                        select 'abc,wuv' from dual union
      3                        select 'abc,pqr,cuq,wuv' from dual
      4                      )
      5  --
      6  -- actual query
      7  --
      8  select str
      9  ,      substr(str, 1, instr(str, ',', -1)-1)||' and '||substr(str, instr(str, ',', -1)+1)
    10  from   sample_data;
    STR             SUBSTR(STR,1,INSTR(STR,',',-1)-1)||
    abc,pqr,cuq,wuv abc,pqr,cuq and wuv
    abc,wuv         abc and wuv
    abc,xyz,wuv     abc,xyz and wuv
    3 rows selected.

  • Search and replace with comma

    Hello All,
    I want some help. Please help me.
    I have comma delimited Data. When I’m converting Sting to Array, If two commas exists in between then its displaying “Zero” (because its array propriety ). Instead of that I want to display “NaN” .
    Please give me any idea to replace comma to NaN. I tried with Search and Replace but it’s not giving as I expected.
    Munna
    Solved!
    Go to Solution.

    Hello GerdW,
    Thanks you so much for your reply.
    I thought, instead of replacing trailing comma by NaN adding comma before string is more better (because to many string manipulations) But, it’s taking more execution time.
    Munna
    Attachments:
    Search and Replace.vi ‏415 KB

  • Comm.jar is used for what?

    I got one post related to comm.jar
    why is is used for I'm new to java technology.
    Can any buddy help me?

    you guys need to Google this kind of stuff and stop hosing up the forums with general questions

  • Resources to information on comm.jar

    hello!! Does anyone know any good links that explains comm.jar in detail?
    I;m currently on a project connection PC to a security panel through RS-232 ^^
    any suggestions will be welcomed! thank you all in advance

    http://java.sun.com/products/javacomm/javadocs/API_users_guide.html

  • Comm.jar not working in Applet but works in Eclipse

    Hello,
    Please help me to read serial port data from Java Applet.
    The below code working well and get data from weighing machine when we run in eclipse(Run Applet). But it now working when we use class file in Applet.
    I think its security issue, but i still could not understand what we need to do.
    I put the JOptionPane.showDialog and found that the code is crashing in line CommPortIdentifier.getPortIdentifiers(); (Not understood why try catch not working.)
    I am using in Windows 7 environment.
    import java.awt.BorderLayout;
    import java.awt.Color;
    import java.awt.event.*;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.util.Enumeration;
    import java.util.logging.Logger;
    import javax.comm.*;
    import javax.swing.*;
    public class SimpleApplet extends JApplet {
    public void init() {
    JButton button = new JButton("Click me!");
    button.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent evt) {                 
         JOptionPane.showMessageDialog(SimpleApplet.this, "hello");
    JOptionPane.showMessageDialog(SimpleApplet.this, Getdata());
    add(button, BorderLayout.CENTER);
    setBackground(Color.GRAY);
    public String Getdata()
         try
              String drivername = "com.sun.comm.Win32Driver";
    try
    CommDriver driver = (CommDriver) Class.forName(drivername).newInstance();
    driver.initialize();
    catch (Exception e) { //just do nothing, it doesn't really matter
         Enumeration portList=null;
    CommPortIdentifier portId;
    SerialPort serialPort;
    OutputStream outputStream;
    try
         portList = CommPortIdentifier.getPortIdentifiers();
    }catch(Exception ex)
         JOptionPane.showMessageDialog(SimpleApplet.this, "erorr:" + ex.getStackTrace().toString());
    JOptionPane.showMessageDialog(SimpleApplet.this, "get port lsit");
              while(portList.hasMoreElements())
                   portId = (CommPortIdentifier) portList.nextElement();
                   if(portId.getPortType()== CommPortIdentifier.PORT_SERIAL)
                        if(portId.getName().equals("COM1"))
                             try
                                  serialPort = (SerialPort) portId.open("WeightMachine",200);                              
                                  serialPort.setSerialPortParams(1200, SerialPort.DATABITS_8, SerialPort.STOPBITS_1,SerialPort.PARITY_NONE);
                                  outputStream = serialPort.getOutputStream();
                                  InputStream mInputFromPort = serialPort.getInputStream();
                                  outputStream.write("W".getBytes());
                                  outputStream.flush();
                                  Thread.sleep(500);
                                  byte mBytesIn [] = new byte[20];
                                  mInputFromPort.read(mBytesIn);
                                  //mInputFromPort.read(mBytesIn);
                                  String value = new String(mBytesIn);
                                  mInputFromPort.close();
                                  serialPort.close();
                                  return value.replace("+00", "").replace(" Kg", "");
                             }catch(Exception ex)
                                  return ex.getMessage();
              }catch(Exception ex)
                   JOptionPane.showMessageDialog(SimpleApplet.this, "erorr last:" + ex.getStackTrace().toString());
              return "Not found";
    Thanks in advance.
    Avinash

    959817 wrote:EJP wrote:959817 wrote:
    it now working when we use class file in Applet.Define 'not working'.But when i run applet from browser from same machine its not working.That's not an answer. That's just a vague and pointless restatement of the original vague and pointless statement that I asked you to clarify.
    When you take your car to a mechanic, do you just tell him it's 'not working'?

  • Replacing several commas in a string

    Hi ,
    Hi ,
    I have string like the following.
    1.,Accenture, , ,EDS,Sun,Training Partner
    2.United States,,,,
    3.Canada,
    I want to have the string like the following as a result of the query.
    1. Accenture,EDS,Sun,Training Partner
    2. United States
    3. Canada
    Help is appreciated.
    _PS
    Here is the script to create table and insert script.
    create table temps
    (val varchar2(1000));
    insert into temps values (',Accenture, , ,EDS,Sun,Training Partner');
    insert into temps values ('United States,,,, ');
    insert into temps values ('Canada,');
    insert into temps values (',Canada ');
    commit;

    Hi,
    You can do this in any version of Oracle, but you should have some excuse ready if you do it in Oracle 10 (or higher):
    SELECT     val
    ,     TRIM
         ( ',' FROM
              REPLACE          -- (4) See notes below
              (     REPLACE          -- (3)
                   (     REPLACE          -- (2)
                        (     REPLACE     ( val     -- (1)
                                  )     -- (1)
                        )          -- (2)
                   )          -- (3)
              )          -- (4)
         )     AS reduced
    FROM     temps
    ;This assumes you know of a string ('??' in this example) that never appears next to a comma.
    In case it's not completely clear what the various REPLACEs are doing:
    (1) Remove single spaces after commas (unlike the REGEXP_REPLACE solution, which removes any number of spaces) The interesting cases now are a single comma (such as 'x,y') or muliple consecutive commas (like 'w,,,z').
    (2) Add '??' AFTER every comma (resulting in 'x,??y' or 'w,??,??,??z')
    (3) Remove all instances of '??,' (that is, the flag BEFORE a comma, resulting in 'x,??y' (no change) or 'w,??z')
    (4) Remove '??' AFTER every comma (resulting in 'x,y' or 'w,z')
    If you really need to remove any number of spaces in step (1), you can use the technique from steps (2)-(4), a total of seven nested REPLACE calls.
    Edited by: Frank Kulash on Oct 31, 2008 5:10 PM
    Actually, this has to be changed to work in Oracle 8 (and earlier)
    The ambidextrous TRIM function was introduced in Oracle 9.
    In earlier versions, you have to nest LTRIM and RTRIM, as in Sy's message (below).

  • Replacing csv commas with tabs

    Has anyone come accross a command, preferably in vi to replace comma's seperated fields with tab delimited fields? I know about the substitution command but as people who work with csv files might know that fields of data with commas in them have quotation marks around them, I need to keep these commas in the file.

    Not sure if I understand this 100%
    But if I do, then this should work:
    `fixcsv.py inputfile outputfile`
    Things that are quoted because they contain a comma will no longer be quoted since thats no longer the delimiter (tab is). Also, you can uncomment the commented out line to have every field surrounded in quotes.
    #!/usr/bin/python
    #fixcsv.py
    import csv
    import sys
    reader = csv.reader(open(sys.argv[1], "rb"))
    writer = csv.writer(open(sys.argv[2], "wb"), delimiter='\t')
    #uncomment next line if you want everything quoted
    #writer = csv.writer(open(sys.argv[2], "wb"), delimiter='\t', quoting=csv.QUOTE_ALL)
    writer.writerows(reader)
    Be sure to backup your data just in case.
    Last edited by sabooky (2007-06-06 05:00:14)

  • Replacement for orionconsole.jar?

    Hi,
    I have installed jDev RC2 and I use the oc4j bundled with it.
    Where is the orionconsole.jar?
    Exists a replacement for it?
    Thanks
    Guenther

    Thanks Debu,
    Now that IDS 9.02 ??? is out on OTN, and I'm presuming (hoping) that my
    order for an IDS CDROM will be version 9, does this version contain all
    that's needed?
    Anybody offer URLs for doc on how to install a commercial and supportable
    instance of OC4J, with all the remote controlability etc features??
    I'm needing to deploy to production, a Deployment Guide for this version
    would be very nice. :)
    Thanks! Curt

  • Replacing a comma with a paragraph mark

    Hello All,
    I have some poor quality address information which is in the form:
    <ADDRESS>1 High Street, Kensington, London, England, SW1<!ADDRESS>
    and on the letter I need to convert it into:
    1 High Street
    Kensington
    London
    England
    SW1
    Any clues how to do this conversion?
    Help appreciated.
    Regards
    Richard

    If the fields remain constant, then you know how many commas are present. Given that, you can instring and substring the entire string based on the commas.
    You can test this out in SQL using a table.
    create table bip (address varchar2(60));
    insert into bip values
    ('1 High Street, Kensington, London, England, SW1');
    In SQL*Plus:
    col a for a13
    col b for a12
    col c for a12
    col d for a12
    col e for a12
    --this will show each part of the address, but all on one line
    select
    --first part
    substr(address,1, instr(address,',',1,1)-1) "A",
    --second part
    substr(address, instr(address,',',1,1)+2, instr(address,',',1,2)-instr(address,',',1,1)-2) "B",
    --third part
    substr(address, instr(address,',',1,2)+2, instr(address,',',1,3)-instr(address,',',1,2)-2) "C",
    --fourth part
    substr(address, instr(address,',',1,3)+2, instr(address,',',1,4)-instr(address,',',1,3)-2) "D",
    --fifth part
    substr(address, instr(address,',',1,4)+2) "E"
    from bip;
    A B C D E
    1 High Street Kensington London England SW1
    --this will line return after each part of the address
    select
    --first part
    substr(address,1, instr(address,',',1,1)-1) ||chr(10)||
    --second part
    substr(address, instr(address,',',1,1)+2, instr(address,',',1,2)-instr(address,',',1,1)-2) ||chr(10)||
    --third part
    substr(address, instr(address,',',1,2)+2, instr(address,',',1,3)-instr(address,',',1,2)-2) ||chr(10)||
    --fourth part
    substr(address, instr(address,',',1,3)+2, instr(address,',',1,4)-instr(address,',',1,3)-2) ||chr(10)||
    --fifth part
    substr(address, instr(address,',',1,4)+2) "ADDRESS"
    from bip;
    ADDRESS
    1 High Street
    Kensington
    London
    England
    SW1
    What you do in Desktop (xpath query) is to write the select part for each element.

  • Replace commons-logging.jar with another version

    Hi all,
    I'm using CR4E version 2 Update 4(v. 12.2.205) and I would use instead of
    commons-logging.jar (v. 1.1.1) provided, the version used in my application
    (v. 1.0.4). Is possible without errors?
    I specify that I not use the provided log4j.jar in CR4E v.2.
    Thanks a lot

    The versions that we provide with our product is the version that we expect to be using when using our product.  Any other version may or may not work and there would be no way to fix an issue specific to using a different version than what we provide.

Maybe you are looking for