user on WINDOWS NT

Posted on 1999-12-26
Medium Priority
Last Modified: 2011-09-20
I would create a delphi program to create new user (with password, mail box on outlook server, ecc. ) within my network WINDOWS NT based.
It's this possible?
You can help me to do this

Question by:poc3796
  • 3
  • 2

Author Comment

ID: 2306709
Edited text of question.

Author Comment

ID: 2306712
Edited text of question.
LVL 20

Expert Comment

ID: 2307287
Use NetUserAdd.

Regards, Madshi.

Author Comment

ID: 2310478
i look for help on win32 and I see that I have to create a data structure to using this Api but I can understand very well how to do this in delphi...

can you help me?

another question: I would add this user also to Exchange server, when I create the user from NT the user manager open the second windows where I can put information I can do this in program

please help
and excuse my bad english
LVL 20

Accepted Solution

Madshi earned 300 total points
ID: 2310590
The structure should look like this:

  TUserInfo1 = packed record
    name         : PWideChar;
    password     : PWideChar;
    password_age : DWord;
    priv         : DWord;
    home_dir     : PWideChar;
    comment      : PWideChar;
    flags        : DWord;
    script_path  : PWideChar;

The function declaration like this:

function NetUserAdd(server: PWideChar; level: DWord; var info: TUserInfo1; var out: DWord) : DWord; stdCall;
         external 'netapi32.dll' name 'NetUserAdd';

Regards, Madshi.

P.S: I didn't understand your "another question". I don't have NT here right now, so I can't check this second window. I can't tell you more than what is written in the NetUserAdd documentation (and perhaps how to use it in Delphi).

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
The video will let you know the exact process to import OST/PST files to the cloud based Office 365 mailboxes. Using Kernel Import PST to Office 365 tool, one can quickly import numerous OST/PST files to Office 365. Besides this, the tool also comes…
From store locators to asset tracking and route optimization, learn how leading companies are using Google Maps APIs throughout the customer journey to increase checkout conversions, boost user engagement, and optimize order fulfillment. Powered …

588 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question