Mombu the Microsoft Forum sponsored links

Go Back   Mombu the Microsoft Forum > Microsoft > sdo, export of users rights and groups
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 18th May 14:59
fguiguiàº(.‰Ø¬rë,Љìš+¢ÊµÊ&
External User
 
Posts: 1
Default sdo, export of users rights and groups



Hello,

Is it possible to export (by sdo) the users "Administrators".

It seems that it exports every users but the administrators.

Thanx
  Reply With Quote


  sponsored links


2 18th May 14:59
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups



Hi,

the following vbs script will export all rights groups. It is not possible
to export only a single rights group.
You need to run it as a CMS administrator.

Dim pCmsDeployExport
Dim shell
Dim pExportOptions

Set pCmsUserGroupBackupRestore =
CreateObject("CmsDeployServer.CmsUserGroupBackupRe store.1")

pCmsUserGroupBackupRestore.AuthenticateAsCurrentUs er()

If ( Err.Number <> 0 ) Then
Call MsgBox(Err.Description, vbCritical, "Backup/Restore PROBLEM")
Set pCmsUserGroupBackupRestore = Nothing
else

strPackageFileName = "c:\export-users.sdo"
strReportUrl = pCmsUserGroupBackupRestore.Backup("strPackageFileN ame")

' Display the report in the Web browser.
Set shell = WScript.CreateObject("WScript.Shell")
shell.Run "http://localhost" & strReportUrl, 7
WScript.Echo "Export complete."

end if


Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------
  Reply With Quote
3 18th May 14:59
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


Sure:

template.Submit();
cmsContext.CommitAll();

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------
  Reply With Quote
4 18th May 14:59
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


See parallel response.

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------
  Reply With Quote
5 18th May 14:59
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


You can be sure that this code will work.
Here is the complete code I use to do this:

using System;
using Microsoft.ContentManagement.Publishing;

namespace ForceTemplateCheckIn
{
class Class1
{
[STAThread]
static void Main(string[] args)
{
CmsApplicationContext cmsContext = new CmsApplicationContext();
cmsContext.AuthenticateAsCurrentUser(PublishingMod e.Update);

Template tpl =
cmsContext.Searches.GetByPath("/Templates/MyTemplates/TestTemplate") as
Template;
Console.WriteLine(tpl.Guid);
tpl.Submit();
cmsContext.CommitAll();
}
}
}

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------

templates are still checked out.
  Reply With Quote
6 29th May 12:58
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


What is the error you receive?

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------


templates allready exist). For the creation of templates it works, but if
the templates allready exist and are only modified we can't submit them
(only in state new or saved).
  Reply With Quote
7 29th May 12:58
fguiguiàº(.‰Ø¬rë,Љìš+¢ÊµÊ&
External User
 
Posts: 1
Default sdo, export of users rights and groups


It's about this :

"Can't submit, template state must new or saved"
  Reply With Quote
8 29th May 12:58
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


Ok, then obviosly it is in a different state. Neither new nor saved...
Lets take that offline: please send me a mail to webmaster@stefan-gossner.de
and I will send you a tool to dump the metastructure of your repository.
This will help me to understand what state these postings are in.
Obviously the tool that creates the templates does not do the things correct
as it creates the templates with strange state.
I'm curios about the outcome of this...

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------
  Reply With Quote
9 29th May 12:58
stefan [msft]
External User
 
Posts: 1
Default sdo, export of users rights and groups


What is the error you receive?

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

MCMS FAQ:
http://download.microsoft.com/download/4/2/5/4250f79a-c3a1-4003-9272-2404e92bb76a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/usersamples/Default.aspx?ProductDropDownList=Content+Management+Server
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossner/archive/2003/12/07/41859.aspx
--------------------------------


templates allready exist). For the creation of templates it works, but if
the templates allready exist and are only modified we can't submit them
(only in state new or saved).
  Reply With Quote
10 29th May 12:58
fguiguiàº(.‰Ø¬rë,Љìš+¢ÊµÊ&
External User
 
Posts: 1
Default sdo, export of users rights and groups


It's about this :

"Can't submit, template state must new or saved"
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666