Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8363911
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T12:18:15+00:00 2026-06-09T12:18:15+00:00

Possible Duplicate: How to use Rundll32 to execute DLL Function? Where can I find

  • 0

Possible Duplicate:
How to use Rundll32 to execute DLL Function?

Where can I find documentation (tutorials, books, etc.) to write my own dll’s that can be run with rundll32.exe?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T12:18:16+00:00Added an answer on June 9, 2026 at 12:18 pm

    Here is the most basic Hello World sample I could come up with that will work with rundll.exe. Please follow along these steps:

    Start a fresh WIN32 DLL project in Visual Studio (I used VS2010)

    In dlllmain.cpp add:

    // this shoud ideally go into the .h file I believe
    __declspec( dllexport ) void CALLBACK EntryPoint(
           HWND hwnd, 
          HINSTANCE hinst, 
          LPSTR lpszCmdLine, 
          int nCmdShow);
    
    // our hello world function
    void CALLBACK EntryPoint(HWND hwnd, HINSTANCE hinst, LPSTR lpszCmdLine, int nCmdShow)
    {
        int msgboxID = MessageBox(
            NULL,
            L"Hello World from Run32dll",
            L"Hello World",
            MB_ICONWARNING | MB_CANCELTRYCONTINUE | MB_DEFBUTTON2
        );
    
        switch (msgboxID)
        {
        case IDCANCEL:
            // TODO: add code
            break;
        case IDTRYAGAIN:
            // TODO: add code
            break;
        case IDCONTINUE:
            // TODO: add code
            break;
        }
    
    }
    

    Add a module.def file to your project and edit the following snippet in it:

    LIBRARY YourDll
    EXPORTS
        EntryPoint
    

    Compile and then test from the commandline with

    rundll32 YourDll.dll,EntryPoint
    

    You should be greeted with a MessageBox with three buttons

    I used the following url’s to overcome C++ issues and EntryPoint not found in the early stages of my effort:

    • Rundll from user mricicle
    • How messagebox works
    • DependencyWalker
    • Exporting functions
    • Exporting with .def file
    • String literals
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: Can I use operators as function callback in PHP? Is it possible
Possible Duplicate: Why use document.write? Considering the negative effects of document.write(), why are most
Possible Duplicate: Can we use any other TAG inside <ul> along with <li>? Or
Possible Duplicate: How to use include within a function? i have two file inc.php
Possible Duplicate: Why use a framework with PHP? To begin with, I just can
Possible Duplicate: Use of 'const' for function parameters For example, void Func(int para); If
Possible Duplicate: Use of class definitions inside a method in Java Can we have
Possible Duplicate: When to Use Static Classes in C# I will write code in
Possible Duplicate: Why use getters and setters? I have read books on Java, saying
Possible Duplicate: How to use my own sqlite database? Full Android Database Helper class

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.