CreateUser

説明

新規ユーザーを作成して、スキーマ リポジトリと関連付けます。

戻されたオブジェクトには情報は含まれていません。このオブジェクトに情報を追加するには、そのプロパティに値を追加します。ユーザー プロパティの詳細については、「User オブジェクト」を参照してください。

構文

VBScript

adminSession.CreateUser(userName) 

Perl

$adminSession->CreateUser(userName); 
識別子
説明
adminSession
AdminSession オブジェクトは、現在のスキーマ リポジトリのアクセス セッションを表します。
userName
新規ユーザーに指定する名前を含む String。
戻り値
新規 User オブジェクト

VBScript

set adminSession = CreateObject("ClearQuest.AdminSession")
adminSession.Logon "admin", "admin", "" 

set newUserObj = adminSession.CreateUser ("jsmith") 

Perl

use CQPerlExt;



# Create a Rational ClearQuest admin session

my $adminSession = CQAdminSession::Build();



# Logon as admin

$adminSession->Logon( "admin", "admin", "" );



# Create the user "jsmith" object

my $newUserObj = $adminSession->CreateUser( "jsmith" );

die "Unable to create the user!¥n" unless $newUserObj;



# Set the new user's password to secret

$newUserObj->SetPassword("secret");



# All done.

CQAdminSession::Unbuild($adminSession); 

フィードバック