Results 1 to 7 of 7

Thread: Calculator API

  1. #1

    Thread Starter
    Addicted Member CodeRonin's Avatar
    Join Date
    Jul 2002
    Location
    Vienna, Austria
    Posts
    233

    Calculator API

    Hello,
    I want to integrate the windows calculator into my program (or any other good calculator if you know a nicer one ), but I need to proceed with the result, so I need a way to store it somehow (doesn't matter wheter I store it in a File, autocopy it, etc.).

    So my questions are:

    -How do I call the win calculator?
    -How do I store the results?
    -Are there any better ways of integrating a good calculator apart from writing one myself?

    Thanks,
    Lukas
    Code Ronin

  2. #2
    Super Moderator manavo11's Avatar
    Join Date
    Nov 2002
    Location
    Around the corner from si_the_geek
    Posts
    7,171
    You can start it by doing :

    VB Code:
    1. Shell "calc.exe", vbNormalFocus

    As for getting the info, go to patorjk.com and download the API spy. From that you can get the hwnd for the box that you want. Afterwards, try searching for the SendMessage API with the WM_GETTEXT constant


    Has someone helped you? Then you can Rate their helpful post.

  3. #3

    Thread Starter
    Addicted Member CodeRonin's Avatar
    Join Date
    Jul 2002
    Location
    Vienna, Austria
    Posts
    233

    thanks

    Thanks, I'll try that. Alternative solutions are still welcome, though.
    Code Ronin

  4. #4
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985
    for .NET
    process.start("calc")

  5. #5
    Super Moderator manavo11's Avatar
    Join Date
    Nov 2002
    Location
    Around the corner from si_the_geek
    Posts
    7,171
    By the way why don't you want to write your own calculator? It will be easier?


    Has someone helped you? Then you can Rate their helpful post.

  6. #6

    Thread Starter
    Addicted Member CodeRonin's Avatar
    Join Date
    Jul 2002
    Location
    Vienna, Austria
    Posts
    233

    Well...

    I've come to this point, too .
    Nah, seriously, I just wanted to trick around with communication between programs.
    Code Ronin

  7. #7
    Super Moderator manavo11's Avatar
    Join Date
    Nov 2002
    Location
    Around the corner from si_the_geek
    Posts
    7,171

    Re: Well...

    Originally posted by CodeRonin
    I've come to this point, too .
    Nah, seriously, I just wanted to trick around with communication between programs.
    OK. I was just wondering . Did you get it to work?


    Has someone helped you? Then you can Rate their helpful post.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width