doubt

Discussion in 'Java' started by AnetaKvel, Jan 19, 2007.

  1. AnetaKvel

    AnetaKvel Guest

    is it possible for any java program written in GUI to execute commands
    on the OS shell interface.
    like is it possible for a Applet or Application to compile and create a
    class file,if so can any body teach me how.
    sorry for my english
    thank you in advance
    AnetaKvel, Jan 19, 2007
    #1
    1. Advertising

  2. AnetaKvel wrote:

    Sub: doubt

    I doubt that 'doubt' is a good title for this thread.
    (Unless you are talking theology, which is off-topic,
    and still does not make it a *good* title)

    Andrew T.
    Andrew Thompson, Jan 19, 2007
    #2
    1. Advertising

  3. On Thu, 18 Jan 2007 22:01:02 -0800, AnetaKvel <>
    wrote:

    > is it possible for any java program written in GUI to execute commands
    > on the OS shell interface.
    > like is it possible for a Applet or Application to compile and create a
    > class file,if so can any body teach me how.
    > sorry for my english
    > thank you in advance


    If I'm understanding what you're trying to ask, then "java.lang.Runtime"
    is probably what you need.

    --
    Randolf Richardson -
    The Lumber Cartel, local 42 (Canadian branch)
    http://www.lumbercartel.ca/
    Randolf Richardson, Jan 19, 2007
    #3
  4. In article <-corporate.com>,
    "Randolf Richardson" <> wrote:

    > On Thu, 18 Jan 2007 22:01:02 -0800, AnetaKvel <>
    > wrote:
    >
    > > is it possible for any java program written in GUI to execute commands
    > > on the OS shell interface.
    > > like is it possible for a Applet or Application to compile and create a
    > > class file,if so can any body teach me how.
    > > sorry for my english
    > > thank you in advance

    >
    > If I'm understanding what you're trying to ask, then "java.lang.Runtime"
    > is probably what you need.


    An applet will be tricky because of security/permissions rules, but the
    Runtime class and its exec methods would indeed allow execution of
    commands on "the OS shell interface" as the OP mentioned.

    As of Java 5, it might be better to look into the new programmatic
    interface to the compiler. On the "new features" page of the JDK5
    documentation it mentions the com.sun.tools.javac.Main class and links
    to <http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/javac.html> to
    describe it. While the link names Solaris, it's my understanding that
    it should work on any supported platform.

    = Steve =
    --
    Steve W. Jackson
    Montgomery, Alabama
    Steve W. Jackson, Jan 19, 2007
    #4
  5. AnetaKvel

    Hal Rosser Guest

    "Andrew Thompson" <> wrote in message
    news:...
    > AnetaKvel wrote:
    >
    > Sub: doubt
    >
    > I doubt that 'doubt' is a good title for this thread.
    > (Unless you are talking theology, which is off-topic,
    > and still does not make it a *good* title)
    >
    > Andrew T.
    >

    I would hazard to guess the word 'doubt' was the result of translating the
    word 'question' from the OP's native language - probably using a translation
    program.
    I may be wrong - but I 'doubt' it. :)
    Hal Rosser, Jan 20, 2007
    #5
  6. Hal Rosser wrote:
    > "Andrew Thompson" <> wrote in message
    > news:...
    > > AnetaKvel wrote:
    > >
    > > Sub: doubt
    > >
    > > I doubt that 'doubt' is a good title for this thread.

    ....
    > I would hazard to guess the word 'doubt' was the result of translating the
    > word 'question' from the OP's native language ...

    ....

    Sounds logical. But note ..
    1) 'Question' is an even worse title.
    2) Translation programs are more likely to be
    able to parse a (linguistically correct) *phrase*
    or sentence, than any *single* word that is
    inherently outside any 'known context'.

    Andrew T.
    Andrew Thompson, Jan 20, 2007
    #6
  7. Andrew Thompson wrote:
    (snip)
    > ... But note ..
    > 1) 'Question' is an even worse title.
    > 2) Translation programs ...


    3) If a poster is very bad at english, it might help
    to *also* post the question again, immediately
    below, in their native language.
    - Firstly, because there might be someone
    about the place who speaks the same
    language, but can translate better to English.
    - Secondly, because someone who does *not*
    speak the same language, but knows some
    key phrases and words, might better translate.
    - And, especially with groups of languages that
    have the same 'roots' (e.g. Latin for most
    European languages), someone that neither
    knows the language, nor recognises key
    phrases in it, might still recognise a word
    with a common root.

    It is all about - communicating the technical problem.

    Andrew T.
    Andrew Thompson, Jan 20, 2007
    #7
  8. AnetaKvel

    AnetaKvel Guest

    Thank you Mr.Richard and Thank you Mr.Steve your replies helped me a
    lot in coding the solution to my lab excercise.
    As for the language discussion, is there any way to post my question in
    Tamil which happens to be my mother tongue, we still do not have any
    translators developed in my country (India) or around the world to
    translate it in to English or any other foreign language(even though
    google search provides an opportunity to use my mother tongue ,it has
    limited operational facility) so the Usenet groups has to bear with my
    poor language. since English is second language to me .if you people
    know anything about the available best translators please provide me
    the link to website. I may use it to post the queries in better phrased
    titles and details. Even if I post in my mother tongue it will I get
    attention from experienced people like you in answering my
    queries???????
    Thank you
    Aneta KVel
    AnetaKvel, Jan 20, 2007
    #8
  9. AnetaKvel wrote:
    > Thank you Mr.Richard and Thank you Mr.Steve your replies helped me a
    > lot in coding the solution to my lab excercise.
    > As for the language discussion, is there any way to post my question in
    > Tamil ...


    Ahh. I was completely forgetting languages based
    on entirely different character sets(?).

    *Very* stupid of me. Sorry.

    >. .....Even if I post in my mother tongue it will I get
    > attention from experienced people like you in answering my
    > queries???????


    *Always* post an english version, the best you
    can do. Note that when you add more words,
    it often makes things more clear.

    But a couple of notes.
    - Your English is a lot better than a lot of other
    people who get a technical solution to their problem.
    - Please fix that sticky '?' key on your keyboard.

    Andrew T.
    Andrew Thompson, Jan 20, 2007
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Igbal

    Doubt to go .Net technology

    Igbal, Nov 8, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    485
    Ed Kaim [MSFT]
    Nov 17, 2003
  2. Bob Nelson

    doubt about doubt

    Bob Nelson, Jul 28, 2006, in forum: C Programming
    Replies:
    11
    Views:
    594
  3. Replies:
    0
    Views:
    537
  4. Peter Otten
    Replies:
    2
    Views:
    102
    Cousin Stanley
    Aug 10, 2013
  5. Terry Reedy
    Replies:
    0
    Views:
    106
    Terry Reedy
    Aug 10, 2013
Loading...

Share This Page