Results 1 to 3 of 3

Thread: Loading and Executing Code??

  1. #1

    Thread Starter
    Addicted Member Virtual24's Avatar
    Join Date
    May 2001
    Posts
    228

    Loading and Executing Code??

    I would like to know if it is possible to load code from a .h or .cpp file and execute it as part of my program.

    Code:
    void LoadCode()
    {
        //Load the .h or .cpp file and get code from it here
    
        // Execute the code that was loaded here
    
        //Continue with normal program
    }
    Is that possible and does anyone know how to do it?
    To protect time is to protect everything...

  2. #2
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Uhhh...
    Yeah. Start the compiler from within your app (or write your own) with the right parameters and then start the resulting program. Or create your own C interpreter. (Yeah, sure!)
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  3. #3

    Thread Starter
    Addicted Member Virtual24's Avatar
    Join Date
    May 2001
    Posts
    228
    OK! Nevermind that crazy Idea... Thanx anyway tho... I found out how to do what i want with dll's.
    To protect time is to protect everything...

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