Newbie- Java simply put, isn't to me

I am totally ignorant about computers & how they work. All I know is the problems that I have when I turn on my PC. For instance, the other night I was at a web site and I was playing a game. The next thing I know is I got dropped from the game & I saw this message, "java script error". I didn't know what it meant and I still don't. I went to my find menu and typed in, java, just to see what i'd find. What I found is too confusing for me to understand.
What I would like to know is, obviously Java does exist in my PC, but is it possible that somehow it got corrupted in some way that caused me to get that error message? I would also like to know in detail how I can determine what version of Java do I have & if need be, how do I go about upgrading to a newer version. As I said, I'm totally lost when it comes to computers and at this point I'm not even sure if this forum is where I need to be. Any reasonable suggestions or help would be greatly appreciated by this "newbie"

Hello there,
If I may say so, if you can create a file (SOME file) in any given programme and save it to any given folder on any of your hard disks, and the next day still remember what sort of file you created and where you put it - then you know a lot more about computers than a coupla folks I know (includes my mother :-) )!
Well I don't know how much you know, so I reckon if you consider yourself "ignorant about computers" then maybe it's not a very good idea to start getting interested in java. I mean it's pretty hard if you simply lack some basics on a topic and then all of a sudden try to become specific. I know myself... I bought my computer because I needed to record a music demo and thought this would be the easiest way to ensure ok quality and the ability to do the recording any time I like myself. It took aaaaaages for me to get the computer to do what I wanted it to... but I needed the basics. And I think if it hadn't been so important to me (and besides I'm very curious about computers on a very broad basis), I would have given up and turned to other things to spend so much time on. But that's something you have to know yourself. If you're really interested, you'll find out. But be assured, it's gonna cost you hours on hours, half of your nights, you'll get square eyes, and if you're not keen on reading then you better not go further. :-)
Anyway... I kinda felt like writing this :-)
So long
fla~

Similar Messages

  • Can I take my SIM Card out of my 3GS and insert it in another 3GS?   My daughter dropped my phone in the toilet tonight.   Can I take my SIM card that I've removed and simply put it in another 3GS phone (a relative's old phone) and it work?

    My 4 year old daughter dropped my 3GS in the toilet tonight.  Otterboxes are not waterproof in case you were wondering. : /   
    While my turned off phone is buried in a bag of rice, is it possible that I can take the now removed SIM card and put it in another 3GS for the interim?  I have an other 3GS (my mom's old one that we use as an iTouch for the kids) on hand that is attached to my apple ID.
    If this is possible, is it as simple as taking out the SIM card in my mom's old phone and replacing it with mine?   And does this mess anything up when / if I'm able to salvage my toilet phone?   Can I take the SIM card and simply put it back in my phone after having used it in the other one?
    Thanks.

    Put the SIM in the other phone and Restore it from Backup in iTunes. If the old one revives reverse the process.

  • Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Apple - Mac OS X - Feedback

  • A java program that isn't behaving as it should be... please help.

    I am trying to get the following code to work but it isn't playing ball.
    I basically want it to download the file from the following url:
    http://www.ecb.int/stats/eurofxref/eurofxref.zip
    But all this seems to do is create the empty zip...
    Could someone please let me know why they think this is not downloading the actual zip?
    import java.io.*;
    import java.net.*;
    * Command line program to download data from URLs and save
    * it to local files. Run like this:
    * java FileDownload http://schmidt.devlib.org/java/file-download.html
    * @author Marco Schmidt
    public class FileDownload {
         public static void download(String address, String localFileName) {
              OutputStream out = null;
              URLConnection conn = null;
              InputStream  in = null;
              try {
                   URL url = new URL(address);
                   out = new BufferedOutputStream(
                        new FileOutputStream(localFileName));
                   conn = url.openConnection();
                   in = conn.getInputStream();
                   byte[] buffer = new byte[1024];
                   int numRead;
                   long numWritten = 0;
                   while ((numRead = in.read(buffer)) != -1) {
                        out.write(buffer, 0, numRead);
                        numWritten += numRead;
                   System.out.println(localFileName + "\t" + numWritten);
              } catch (Exception exception) {
                   exception.printStackTrace();
              } finally {
                   try {
                        if (in != null) {
                             in.close();
                        if (out != null) {
                             out.close();
                   } catch (IOException ioe) {
         public static void download(String address) {
              int lastSlashIndex = address.lastIndexOf('/');
              if (lastSlashIndex >= 0 &&
                  lastSlashIndex < address.length() - 1) {
                   download(address, address.substring(lastSlashIndex + 1));
              } else {
                   System.err.println("Could not figure out local file name for " +
                        address);
         public static void main(String[] args) {
              for (int i = 0; i < args.length; i++) {
                   download(args<i>);

    Hello Mendez,
    it is hard to say what the problem is in your case, but my guess is that you are trying to download from some location where you don't normally connect to the internet directly but access URLs via a proxy server.
    In that case you would have to replace the fourth line in the try-block with code like this
    conn = url.openConnection(new Proxy(Proxy.Type.HTTP,
                                        new InetSocketAddress("<proxyHostName>", <proxyPort>)));
    where proxyHostName and proxyPort will have to be set to the values that apply to you.
    Let me know if this works. If it doesn't, do you get any error message?
    Regards,
    Jens

  • Create Dynamic Variable in LabView (Newbie Java Developer)

    Guys,
    This is my issue, I am a java & c++ developer and was interested in learning about LabView. But as simple as stated by the NI website it's not as trivial as I would expect it to be maybe because of my though process. So what I'm trying to obtain a simple sample to get me started with my LabView.
    Example in Java lets say I prompt a user to enter a value the user enters the [value=20] & I would be able to create [value=20 new Objects] or what ever value the user enters. In LabView things doesn't seem to work that way. So I was hoping someone coulde provide a simple non trivial example so I can better understand how to apply this.
    Thanks for you feedback
    Solved!
    Go to Solution.

    Hi *E*
    I come from a Java background too so might be able to help. I've found that LabVIEW is less demanding upon the programmer to necessarily specify the capacity or number of variables being created during development and does a little more intuitively in the background. 
    What data types are you interested in specifically? From your post I'd be tempted to use an 'Initialize Array' subVI and simply wire the user's input to the dimension size input.
    In LabVIEW it's considered good practice to use wires in place of variables wherever possible because they emphasize the flow of data through the program.
    Does this help a little?
    Chris | Applications Engineer NIUK
    Attachments:
    PromptElements.vi ‏42 KB

  • Newbie question with puts/gets

    I'm having trouble getting put and gets to work. Right now I do an insert into the DB (returns 0) with data in the data.data fields and then when I get it I always get empty space. I was hoping that someone might be able to help. Here is the two snippets of code that I'm using:
    int
    insert_data(DHT_DBS my_dbs, Message *msg)
        DBT key, data;
        char myData[(u_int32_t)strlen(msg->payload)];
        char myKey[41];
        memcpy(&myData,(msg->payload), (u_int32_t)strlen(msg->payload));
        memcpy(&myKey,(msg->dest.keystr), 41);
        printf("in insert\n");
        /* Zero out the DBTs */
        memset(&key, 0, sizeof(DBT));
        memset(&data, 0, sizeof(DBT));
        key.data = msg->dest.keystr;
        data.data = msg->payload;
        data.size = (u_int32_t)strlen(msg->payload);
        /* Put the data into the database */
        int val = 0;
        val = my_dbs.dht->put(my_dbs.dht, 0, &key, &data, 0);
        printf("after put %d\n", val);
        return 0;
    void get_data(DHT_DBS * my_dbs, Message *msg)
        DBT key, data;
        char myData[200];
        int ret;
        /* Initialize our DBTs. */
        memset(&key, 0, sizeof(DBT));
        memset(&data, 0, sizeof(DBT));
        memset(&myData,0,200);
        key.data = msg->dest.keystr;
        key.size = sizeof(Key);
        data.data = &myData;
        data.flags = DB_DBT_USERMEM;
        ret = my_dbs->dht->put(my_dbs->dht,NULL, &key, &data, 0);
        if (ret) {
            printf("No records found for '%s'\n", msg->dest.keystr);
        else
            printf("Record found\n");
            printf("Found: %s\n", myData);
            // if we did find what they were looking for, send a get_response message to the source
            // we may need to add another object to the message struct
    }I'm just trying to test this. my main simply calls the following after I define the variables and open the data bases:
    insert_data(mydb,m);
    get_data(&mydb, m);Now the interesting thing is it does find the key that I inserted with insert_data. However, the data stored with the key is always "" and not the characters that it should be. I'm just wondering if I'm doing something wrong. Any tips would be appreciated.

    Alright I'm back to a different problem now.
    int
    insert_data(DHT_DBS my_dbs, Message *msg)
        DBT key, data;
        char myData[(u_int32_t)strlen(msg->payload)];
        char myKey[41];
        memcpy(&myData,(msg->payload), (u_int32_t)strlen(msg->payload));
        memcpy(&myKey,(msg->dest.keystr), 41);
        printf("in insert\n");
        /* Zero out the DBTs */
        memset(&key, 0, sizeof(DBT));
        memset(&data, 0, sizeof(DBT));
        key.data = msg->dest.keystr;
        data.data = msg->payload;
        data.size = (u_int32_t)strlen(msg->payload);
        /* Put the data into the database */
        int val = 0;
        val = my_dbs.dht->put(my_dbs.dht, 0, &key, &data, 0);
        printf("after put %d\n", val);
        return 0;
    void get_data(DHT_DBS * my_dbs, Message *msg)
        DBT key, data;
        char myData[200];
        int ret;
        /* Initialize our DBTs. */
        memset(&key, 0, sizeof(DBT));
        memset(&data, 0, sizeof(DBT));
        memset(&myData,0,200);
        key.data = msg->dest.keystr;
        key.size = sizeof(Key);
        data.data = &myData;
        data.flags = DB_DBT_USERMEM;
        ret = my_dbs->dht->get(my_dbs->dht,NULL, &key, &data, 0);
        if (ret) {
            printf("No records found for '%s'\n", msg->dest.keystr);
        else
            printf("Record found\n");
            printf("Found: %s\n", myData);
            // if we did find what they were looking for, send a get_response message to the source
            // we may need to add another object to the message struct
    }I corrected that to reflect the get, but now the put doesnt' seem to be working. I thought I followed getting_started example pretty closely. Ret is -30989 when it attempts the get but the put returns 0.

  • Newbie Java Question

    Hi
    I am running jasper reports through an oracle DB connection and am having some problems with a piece of Java code in the report. The code is used in one of the variables of the report and within the code I am manipulating a user input parameter for display purposes. The user would put in a 14 digit code to restrict the report results to this code but one of the requirements for the report is to display the code restricted by the user in a spaced format on the report heading like A012 123 123 123 3 as per requirements. The variable is used as part of the overall report header message and the expression for this variable is as below:
    ($P{Inputparam}.replaceAll( " ", "" ).substring( 0, 4 )
    + " " + $P{Inputparam}.replaceAll( " ", "" ).substring(4, 7)
    + " " + $P{Inputparam}.replaceAll( " ", "" ).substring(7, 10)
    + " " + $P{Inputparam}.replaceAll( " ", "" ).substring(10, 13)
    + "  " + $P{Inputparam}.replaceAll( " ", "" ).substring(13, 14))The user could put in the code with no spaces or multiple spaces and so it is required to remove all spacing from the parameter number then reapply the correct spacing for each part of the code. The problem I am having is handling when the user clears the parameter input value, which leaves an empty string, then the report falls over because the code above is currently not handling an empty string.
    I would appreciate any suggestions to be able to handle an empty string within the code above.
    Thanks
    User605593
    Edited by: user605593 on May 26, 2011 3:03 AM

    I would appreciate any suggestions to be able to handle an empty string within the code above.Not sure if I understand you correctly.
    Do a null check (var != null) and use the String.isEmpty() method to do validation of empty strings.
    But I think you also need to validate the length of the user input after removing the white spaces. Your code will not work if the user gives a 13 char input.

  • Coherence Help standalone java program put data in cache & Servlet to Read

    Hi,
    I have coherence 3.4 and using Oracle Application Server 10.1.3 We are in the process of developing a Web Application and want to use Coherence for caching the data. My Coherence is also installed on the same box as Oracle Application Server 10.1.3 need some help in storing the data in the coherence and reading it through the servlet. We have standalone java program that needs to put data in the cache and through servlet want to read that and display it on the page. When running the client the data is stored in the cache but when reading it through the servlet it returns null. We have included both coherence.jar and tangosol.jar in the war file and also in the path when running the standalone java program. Started the Coherence using the below command:
    C:\oracle\coherence\lib>java -cp coherence.jar -Dtangosol.coherence.cacheconfig=C:/oracle/coherence/tests/cache-config.xml com.tangosol.net.DefaultCacheServer
    here is the sample config file used when starting the server above:
    <?xml version="1.0"?>
    <!DOCTYPE cache-config SYSTEM "cache-config.dtd">
    <cache-config>
        <caching-scheme-mapping>
            <cache-mapping>
                <cache-name>VirtualCache</cache-name>
                <scheme-name>default-distributed</scheme-name>
            </cache-mapping>
        </caching-scheme-mapping>
        <caching-schemes>
            <!--
            Default Distributed caching scheme.
            -->
            <distributed-scheme>
                <scheme-name>default-distributed</scheme-name>
                <service-name>DistributedCache</service-name>
                <backing-map-scheme>
                    <class-scheme>
                        <scheme-ref>default-backing-map</scheme-ref>
                    </class-scheme>
                </backing-map-scheme>
            </distributed-scheme>
      <class-scheme>
                <scheme-name>default-backing-map</scheme-name>
                <class-name>com.tangosol.util.SafeHashMap</class-name>
                </class-scheme>
    </caching-schemes>
    </cache-config>And here is the standalone java program to put the data in the cache:
    import com.tangosol.net.CacheFactory;
    import com.tangosol.net.NamedCache;
    public class PutCache {
        public PutCache() {
        public static void main(String[] args) {
            PutCache putCache = new PutCache();
            NamedCache         cache = CacheFactory.getCache("VirtualCache");
            String key = "hello";
            cache.put(key, "Hello Cache123123");
    }And here is the Servlet code to read the data but it somehow returns null
    import com.tangosol.net.CacheFactory;
    import com.tangosol.net.NamedCache;
    import java.io.IOException;
    import java.io.PrintWriter;
    import javax.servlet.*;
    import javax.servlet.http.*;
    public class Servlet1 extends HttpServlet {
        private static final String CONTENT_TYPE = "text/html; charset=windows-1252";
        public void init(ServletConfig config) throws ServletException {
            super.init(config);
        public void doGet(HttpServletRequest request,
                          HttpServletResponse response) throws ServletException, IOException {response.setContentType(CONTENT_TYPE);
            PrintWriter out = response.getWriter();
            NamedCache         cache = CacheFactory.getCache("VirtualCache");
            String value = (String)cache.get("hello");
            out.println("<html>");
            out.println("<head><title>Servlet1</title></head>");
            out.println("<body>");
            out.println("<p>The servlet has received a GET. This is the reply.</p>"+value);
            out.println("</body></html>");
            out.close();
    }Is there any other configuration I need. Any help is really appreciated.
    Thanks

    Hi,
    While starting the coherence using
    C:\oracle\coherence\lib>java -cp coherence.jar -Dtangosol.coherence.cacheconfig=C:/oracle/coherence/tests/cache-config.xml com.tangosol.net.DefaultCacheServer
    while running standaone jave program using the below command
    java -Dtangosol.coherence.cacheconfig=C:/oracle/coherence/tests/cache-config.xml Populatecache
    In the Web Application don't have any reference to cache-config.xml just using the coherence.jar & tangosol.jar.
    What are the steps or configurations I need in order to connect to the same Coherence Cache. Do I need to provide some host:port for the Coherence for storing the data in the cache. How does the java client program and Web Application knows to connect to the Coherence. As currently even if I don't start the coherence server and just run the java standalone program it goes and executes fine wondering wher exactly does it persists the cache if coherence itself is not started or just adding the jars is enough. Any help is appreciated.
    Thanks

  • XP Newbie Java P. & JRE Confusion Updates & Error

    Hi!
    I posted this in TechArena, and received a post in reply that suggested I should post here instead...
    I'm an eternal newbie with computers though I never stop trying to learn. I've looked through many posts & don't see an answer to my questions, so I hope this is the right place to ask them.
    I have a Dell Inspiron 1300 laptop with XP Home v. 5.1.266. I use Firefox and AVG. My computer was getting slow and in the last few days some programs started crashing. Today Corel Photo Album crashed. In trying to google the error report I found something mentioned about Java needing old versions deleted, so I checked mine. And this is where I got confused.
    Firest of all, I don't understand what the difference is between "Java Platform" and Java Runtime Environment" and I don't understand which version I should have of each. What I do have is:
    Java 2 Runtime Environment, SE v1.4.2_03
    Java ™ 6 Update 14
    Version 6.0.140
    Java ™ 6 Update 7
    Version 1.6.0.70
    Could someone one tell me what I should have on my computer?
    Also, I read in a post that one shouldn't install an update until the old versions are deleted, yet in another post (somewhere) it said to update and then delete the old versions. I don't know which to believe. Could I get some advice on which is correct?
    Thank you very much!
    dorij

    Thanks for the advice. I did what you said. Then Spybot did a whole scan which took a while. When it returned the computer to me, all the versions of Java were gone from Add/Delete programs. I decided to do a search on "java" just to see what came up. A huge list came up; things like Java Plug.doc, java_install_reg.log, a folder labeled javaws thats located in Sun\Java\Deployment. I'd copy the list, but I don't know how. There are about 89 items on the list.
    Should these files be there? I haven't yet reinstalled the correct update.
    Thanks again.
    dorij

  • Newbie Java Card

    Hello ,
    new in the forum, and to the java card technology. Just wanted to see if someone to help me.
    Needing to find a good tutorial. Just to learn, how to do a "Hello world" using JCRMI.
    Looking things like :
    - the code for the Hello World
    - And how to simulate in a pc with vista. Without a card reader.
    - And any tool to use on eclipse
    Until now haven't understand so far how to put things working.
    Thanks

    Refer this
    [http://forums.sun.com/thread.jspa?messageID=10604165|http://forums.sun.com/thread.jspa?messageID=10604165]

  • When I begin to type "m" in the location bar, I simply cannot -- it always changes it to an "h". Simply put, I can't type a simple URL. What gives? (FF 7.0.1)

    Basically, I'm trying to go to a mobile version of my own site to see something, so I start typing, "m.mysite..." and it just won't let me do it. I have to open Notepad, type the URL, then paste it in the URL bar. I must be breaking someone's new self-imposed rule that typing a URL with an 'm' isn't "standards-compliant" for a non-mobile device (just a lame jab, sorry, I'm sort of frustrated here).

    Do you have enabled auto-fill for the location bar?
    You can check the pref browser.urlbar.autoFill on the <b>about:config</b> page.
    You can also make the protocol visible.
    You can set the pref <b>browser.urlbar.trimURLs</b> to <i>false</i> on the <b>about:config</b> page to see the http: protocol.
    You can set the pref <b>browser.urlbar.formatting.enabled</b> to <i>false</i> on the <b>about:config</b> page to disable the highlighting of the domain and see the full URL more clearly.
    *[https://bugzilla.mozilla.org/show_bug.cgi?id=678352 bug 678352] - 'h' entered as first letter in location bar is overwritten with 'w' when browser.urlbar.autoFill is true

  • Newbie: Java/JDBC best approach

    Hello, i am having trouble understanding the best approach to develop java/jdbc programs.
    I was told that the i could best load resultset data in to value objects loaded into a vector
    and handled by data access objects instead of using the resultset directly.
    This method should give me more flexibility when navigating, inserting, updating and
    deleting rows.
    An example is given by Matthew Robinson and Pavel Vorobiev in their book
    (http://manning.spindoczine.com/sbe/).
    So i am desperately seeking for sample code or documentation on this matter.
    Matthew Robinson and Pavel Vorobiev do not give a full solution containing r/w/u
    functionality.
    When seeking on the web i find only references to J2EE and this would be
    overkill for the applications i have in mind at this moment.
    I am afraid i will re-invent the wheel and end up with a square one.
    Therefore in short my questions:
    1. Should i use and manipulate the (scrollable, updatable) resultset or use
    value objects handled by data access objects.
    2. Where can i find sample code or documentation on this matter (not J2EE).
    I would be very gratefull if someone could help me,
    Rob

    Hi,
    Contact me at [email protected] I will be able to help you... and provide some sample code.
    regards,
    Nish

  • Java newbie: java.lang.Object[]

    Hi: I have a method which returns a java.lang.Object[]. I have tried a number of things. But can't seem to How do I print the contents of the object?
    The method I am calling is the following
    ==============
    public java.lang.Object[] getAllUsers() {
    if (super.cachedEndpoint == null) {
    throw new org.apache.axis.NoEndPointException();
    org.apache.axis.client.Call _call = createCall();
    call.setOperation(operations[125]);
    _call.setUseSOAPAction(true);
    _call.setSOAPActionURI("");
    call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11CONSTANTS);
    _call.setOperationName(new javax.xml.namespace.QName("Urn:ApiService", "getAllUsers"));
    setRequestHeaders(_call);
    setAttachments(_call);
    try {        java.lang.Object _resp = _call.invoke(new java.lang.Object[] {});
    if (_resp instanceof java.rmi.RemoteException) {
    throw (java.rmi.RemoteException)_resp;
    else {
    extractAttachments(_call);
    try {
    return (java.lang.Object[]) _resp;
    } catch (java.lang.Exception _exception) {
    return (java.lang.Object[]) org.apache.axis.utils.JavaUtils.convert(_resp, java.lang.Object[].class);
    =============
    Thanks
    Ravi

    Where in that code do you claim you are doing that? Post a SSCCE .
    edit: Should you really be trying to work with web services if you don't know the basics of Java?

  • Newbie java - rpc question

    we have the following situation: old server written in C++ running on a defined set of platforms, using rpc to expose its services. modifications of the server should be avoided. what would be the best way to access rpc from java? as I see it (and considering a defined and small set of platforms) implementing rpc calls in C-functions and calling them from java would be a good solution. are there any better ways?
    thanks in advance
    milan

    thanks.
    I have one more question regarding this configuration:
    lets say, i have already developed rpc-enabled-classes. now, if i would like to use these classes in a servlet/jsp-based layer running on a different machine (with a possible firewall between them) then I would implement an RMI server executing rpc-classes and access those classes from servlet/jsp over RMI, right?
    my first idea was to use EJB with rpc-classes, but EJB do not support native methods.
    are there any alternatives to this?

  • Newbie - java app error

    hi...
    i'm new to java. i'm trying to install java (1.4.1) on a redhat linux (8.0) and trying to get the following test app to run... i'm getting an error when i try to run, so i don't know the actual cause of the error. i might have the java environmebt set incorrectly, or the test app may not be correctly written (it was on one of the java install sites that i was using as i was installing...)
    i have JAVA_HOME as a environment var
    i seem to have the "correct" dir structure for java on the system
    i can do java -version.. and get version of the java environment
    - can do javac .. and i get the list of attributes...
    i have the following test app in a separate dir
    import java.lang.reflect.Array;
    class Test
    public static void main( String argv[] )
    System.out.println( "Arguments:" );
    int i = 0;
    while( i < Array.getLength(argv) )
    System.out.println( argv );
    i++;
    i can compile it with no apparent issues...
    when i ->> java test q1 q2 q3
    i get the following error..
    Exception in thread "main" java.lang.NoClassDefFoundError: test
    i can't seem to find a good explanation using google as to what this means, or what's causing it..
    any help/assistance would be appreciated!
    thanks
    bruce
    [email protected]

    Hihi,
    this error...
    Exception in thread "main" java.lang.NoClassDefFoundError: test
    means they cannot find your class file... check if your java file and your class file is in the same folder...
    Regards,
    dimitri_can

Maybe you are looking for