Highlighted
Absent Member.. Absent Member..
Absent Member..
1371 views

OTA script to delete users

Jump to solution


hello there,
we have more than 3000 users need to be deleted from ALM11.52 siteadmin for user cleanup purpose, it would take us long time if do it manually through siteamdin UI, i am looking for some OTA API vbscript to delete those users. any suggestion would be much appreciated.

thanks in advance.
Jen

0 Likes
1 Solution

Accepted Solutions
Highlighted
Absent Member.. Absent Member..
Absent Member..

 

set m_SAClient = CreateObject("SAClient80MP.SAapi") solved the issue.

View solution in original post

0 Likes
5 Replies
Highlighted
Absent Member.. Absent Member..
Absent Member..

Are you looking for somebody to give you the code?

 

You should be looking at the Site Admin API, not the OTA API.

[If this post solves or helps solve your issue, mark the thread as solved and give KUDOS to the author for their assistance.]

(Opinions expressed in my postings are mine alone, and do not reflect the opinions of my employer.No warranties express or implied for any solution/suggestion posted.)
Highlighted
Established Member..
Established Member..

From the manual

 

Public Function DeleteUser( _
ByVal UserName As String _
) As String

 

Private Sub DeleteUser()

'The following Visual Basic example deletes a user.
Dim sReply As String

On Error GoTo err
sReply = m_SAClient.DeleteUser("alex_td")
If (sReply = "1") Then
MsgBox "User Deleted"
End If
Exit Sub

err:
MsgBox "Program failed:" + err.Description
End Sub


~Have you Read The Felicitous Manual?
~Please hit the KUDOS button if my reply helped resolve your issue.
Highlighted
Absent Member.. Absent Member..
Absent Member..

thanks for the suggestion, i looked at the SA API, there is one issue i can not figure out.

 

how do i create the m_SAClient object? i tried the following way but none of them worked.

 

'm_SAClient = CreateObject(“SAClient.SaApi.9”)
m_SAClient = CreateObject("SAClient80MP.SAapi")
'Set m_SAClient = New SAapi
'Set m_SAClient = new SACLIENTLib.SAapi

 

 

Thanks,

Jen

0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..

 

set m_SAClient = CreateObject("SAClient80MP.SAapi") solved the issue.

View solution in original post

0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..

Hi,

Even I have the same question, need help with OTA API script for delete users.

I do not have any experience working with APIs,

So how do I get started with this?

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.