Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 10 of 10

Thread: how do I test my code on a tablet?

  1. #1
    Junior Member
    Join Date
    Jun 2014
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question how do I test my code on a tablet?

    My questions evolve based on your response to each of them.

    One: is it possible to test code offline with one device, preferably an android tablet?

    Two: if, not, is it possible, online with just an android tablet?

    Three:if not, is it possible using the internet on my smart phone and with no internet on my tablet - and no, I can't use my smartphone as a hotspot?

    I want to test code I wrote on droid edit. An app I purchased for writing code. I'm using Java.


  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: how do I test my code on a tablet?

    The Android execution environment is not the same as that for PCs. Code must be specially written for the environment that it is to execute in.

    There are simulators that support the execution of Android programs on a PC. Oracle's VirtualBox for example will execute an Android virtual machine for testing Android apps on a PC.
    If you don't understand my answer, don't ignore it, ask a question.

  3. #3
    Junior Member
    Join Date
    Feb 2014
    Location
    Finland
    Posts
    25
    My Mood
    Bored
    Thanks
    3
    Thanked 5 Times in 5 Posts

    Default Re: how do I test my code on a tablet?

    Errm.. im not 100% sure on what you are trying to do, but from what i gather, Droid Edit is just an editor. You'd need a way to complie it to bytecode. Android doesn't run the JVM bytecode either but Dalvik.

    Your questions about testing code online or offline doesn't make sense to me. Maybe i am missing something here?

    There is the scripting layer SL4A if you want to try and run scripts directly on your device. And then there is the AIDE (android ide) that apparently has some kind of compiler in it, but i haven't tried either. Whats wrong with making the programs on a computer and running them on the device - like the rest of us?

  4. #4
    Junior Member
    Join Date
    Jun 2014
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: how do I test my code on a tablet?

    Thank you, makes sense.

    To be clear, I'm not writing anything major, just very simple sentences with Java, so I don't think it would make a difference with which device I'm using but I defer to the expertise here.

    --- Update ---

    Well, I don't currently have a computer. I figured I could save money just using what I have now - a tablet, but I'm not sure anymore.

  5. #5
    Junior Member
    Join Date
    Jun 2014
    Posts
    22
    My Mood
    Starving
    Thanks
    1
    Thanked 8 Times in 6 Posts

    Default Re: how do I test my code on a tablet?

    I would think that the app you are using would allow you to run (test) your code.


    If not there are definitely apps out there for compiling and running java, however, they aren't as robust as what you would get on a full blown computer.

    There are some websites that will let your run code but they can be even more basic than the apps that are available.

  6. #6
    Junior Member
    Join Date
    Jun 2014
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: how do I test my code on a tablet?

    Quote Originally Posted by koder632417 View Post
    I would think that the app you are using would allow you to run (test) your code.


    If not there are definitely apps out there for compiling and running java, however, they aren't as robust as what you would get on a full blown computer.

    There are some websites that will let your run code but they can be even more basic than the apps that are available.
    Thank you for your feedback. However, I'm yet to find an app that let's me run Java code to test it out. Though I've only skimmed.

  7. #7
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: how do I test my code on a tablet?

    The AIDE app for Android is free from Google Play Store. It will compile and execute programs on a tablet.
    If you don't understand my answer, don't ignore it, ask a question.

  8. #8
    Junior Member
    Join Date
    Jun 2014
    Posts
    22
    My Mood
    Starving
    Thanks
    1
    Thanked 8 Times in 6 Posts

    Default Re: how do I test my code on a tablet?

    I have an iPhone and use an app called JVM....something something. All I know is it starts with JVM. Maybe you can search for JVM instead?

  9. #9
    Junior Member
    Join Date
    Jun 2014
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: how do I test my code on a tablet?

    I have the App. It doesn't allow you to import or manipulate the text outside the lesson plan...at least not the free version.

  10. #10
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: how do I test my code on a tablet?

    Use an editor to change the source.
    If you don't understand my answer, don't ignore it, ask a question.

Similar Threads

  1. Uncomplete code to test another program
    By Gerock7 in forum What's Wrong With My Code?
    Replies: 0
    Last Post: April 17th, 2014, 12:51 PM
  2. Replies: 4
    Last Post: May 7th, 2013, 07:31 AM
  3. dunno how to test this code so i dont know if it works help please
    By jonathanfox in forum What's Wrong With My Code?
    Replies: 5
    Last Post: July 24th, 2012, 04:43 AM
  4. not sure if my code is right, if it is not sure how to code Test box.
    By Smurf83 in forum Object Oriented Programming
    Replies: 3
    Last Post: June 19th, 2012, 11:12 AM