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

  • SEARCH
  • Home
  • 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 7555733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T11:41:05+00:00 2026-05-30T11:41:05+00:00

I am trying to start a server using CreateProcess(). Here is the Code: int

  • 0

I am trying to start a server using CreateProcess(). Here is the Code:

int APIENTRY WinMain(HINSTANCE hInstance,
                     HINSTANCE hPrevInstance,
                     LPSTR     lpCmdLine,
                     int       nCmdShow)
{
    // TODO: Place code here.

    int result; 
    STARTUPINFO si;
    PROCESS_INFORMATION pi;
    CreateProcess("C:\\AP\\DatabaseBase\\dbntsrv.exe", "*** WHAT SHOULD I PUT HERE***", NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi);
    return 0;
}

I did not understand from the documentation what the 2nd parameter should be. Can you please help me with it?
Thank You

  • 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-05-30T11:41:08+00:00Added an answer on May 30, 2026 at 11:41 am

    From MSDN:

    lpCommandLine [in, out, optional]

    The command line to be executed. The maximum length of this string is 32,768 characters, including the Unicode terminating null
    character. If lpApplicationName is NULL, the module name portion of
    lpCommandLine is limited to MAX_PATH characters.

    The Unicode version of this function, CreateProcessW, can modify the contents of this string. Therefore, this parameter cannot be a
    pointer to read-only memory (such as a const variable or a literal
    string). If this parameter is a constant string, the function may
    cause an access violation.

    The lpCommandLine parameter can be NULL. In that case, the function uses the string pointed to by lpApplicationName as the
    command line.

    So NULL is OK there, at least. As soon as you don’t pass arguments.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to start using plain text files to store data on a server,
I am trying to start a service from the command line using net start
I'm trying to start using LINQ and specifically LINQ to SQL but I'm having
I'm trying to start a program using QProcess (Qt4.4 on vista64bit, developing in MSVC2005).
I'm trying start java application but in browser i see standard tomcat's page. Server
I am trying to setup a simple UDP client and server using Ruby. The
I'm trying to make a simple http client server using java. It will show
I'm trying to subclass an unmanaged statusbar window from my managed COM server using
I'm trying to upload an image from android to a PHP server by using
i am geting folloing error when i am trying to start orbited server C:\Python26\Scripts>orbited

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.