Top.Mail.Ru
Мастера DELPHI, Delphi programming community Титульная страница Поиск, карта сайта Написать письмо 
| Новости | Поиск | FAQ | Статьи | Книги | Новости VCL |
| Форумы ЧАТ | Орешник | KOL и MCK |
Форумы -» Основная («Начинающим»)/ Базы / WinAPI / Компоненты / Сети / Media / Игры / Corba и COM / KOL / FreePascal / .Net / Прочее / RSDN.ORG

« предыдущая ветвь | форум | следующая ветвь »

Создание сервиса [WinXP]


han_malign ©   (2004-07-07 17:02:00) 

Какого ..., когда делаю CreateService, с логином
   FSvcHandle := CreateService(FSCMHandle, PChar(ASvcName), PChar(ADisplayName),
     SERVICE_ALL_ACCESS, SERVICE_WIN32_OWN_PROCESS or SERVICE_INTERACTIVE_PROCESS,
     SERVICE_AUTO_START, SERVICE_ERROR_NORMAL, PChar(ABinaryPathName),
     nil, nil, nil, 'DOMAIN\User', 'Password');

- эта зараза ругается "A parameter that was specified is invalid."???
Пользователь есть - на "The account name is invalid or does not exist." не ругается... Без логина тоже все Ob. (Права администратора)


han_malign   (2004-07-08 12:19:00) [1]

а ларчик просто открывался
If you specify either SERVICE_WIN32_OWN_PROCESS or SERVICE_WIN32_SHARE_PROCESS, and the service is running in the context of the LocalSystemaccount, you canalso specify the following type.
SERVICE_INTERACTIVE_PROCESS  - The service can interact with the desktop.

- то есть если с логином - никаких SERVICE_INTERACTIVE_PROCESS


Reindeer Moss Eater   (2004-07-08 11:04:00) [2]

У администратора нет таких прав по умолчанию


han_malign   (2004-07-08 11:02:00) [3]

> Аккаунту разрешено входить в систему в качестве службы?
права атминистратора


Reindeer Moss Eater   (2004-07-08 09:02:00) [4]

Аккаунту разрешено входить в систему в качестве службы?


Cobalt   (2004-07-07 21:43:00) [5]

Попробуй опустить всякие флаги типа SERVICE_ALL_ACCESS в 0, может запашет?
Может, в статье комбинации какие запрещены?
Пути точно правильные?
Отключи оптимизацию...


han_malign   (2004-07-07 17:57:00) [6]

lpServiceStartName

Points to a null-terminated string. If the service type is SERVICE_WIN32_OWN_PROCESS, this name is the account name in the form of "DomainName\Username", which the service process will be logged on as when it runs. If the account belongs to the built-in domain, ".\Username"can be specified. Services of type SERVICE_WIN32_SHARE_PROCESS are not allowed to specify an account other than LocalSystem. If NULL is specified, the service will be logged on as the "LocalSystem" account, in which case, the lpPassword parameter must be NULL.


Если домен\пользователь неправилно указать, то - "The account name is invalid or does not exist."


clickmaker   (2004-07-07 17:39:00) [7]


> han_malign ©   (07.07.04 17:02)  

а если в форме user@domain ?


Наверх

Титульная страница Поиск, карта сайта Написать письмо