Add one computer in multiple collection

Hi

I try to add one computer in multiple collection?

I try this: http://www.sccm-tools.com/tools/rightclick/Rightclick-Collectionaddcomputers.html

but i have error line:89 "oCollection".

Do you have another solution?

Thanks

February 23rd, 2015 11:14pm

Is this only happen on a certain collections?

When I look at line 89 I have '''''

is it this line :
   oCollection.RequestRefresh True

or is the acutal code that adds it to the colleciton? :     oCollection.AddMembershipRule oCollectionRule

Free Windows Admin Tool Kit Click here and download it now
February 24th, 2015 6:10pm

Hi

The line 89 is "oCollection.RequestRefresh True".

When i start "addtocollections.hta" i able to enter a computer name but i unable to enter a collection name  and i have error when i click on "Add toCollection"?

February 24th, 2015 6:26pm

Has this worked before or is this the first time?  You have permissions to add to a collection? 

You right click on the collection you wish to add to.  What is the name of the collection? Does it have any special characters in it?

The refesh line is run after all the machines are added to the collection, then it kicks off a refresh of the collection. 

You can remark out that line of code and see if it still adds the machines for you.

Free Windows Admin Tool Kit Click here and download it now
February 24th, 2015 6:32pm

Hi

Yes, no problem to add a computer in collection because "server admin" and "Admin SCCM".

Presently i use a right-clic tool, right clic on collection and choose "ConfigMgr Collection Tools" "Add Systems to a Collection"? but is very long because i have many collection?

I have a 3 sites, i try a tool on all site and i have a same error message.

I retry: Double clic on "addtocollections" Enter a computer name (EX:123456) and clic "OK". When i clic on "Add to collections":

Title: Script Error

Message: An error has occured in the script on this page

Line: 89

Char:4

Error: Object required 'oCollection'

Code: 0

Thanks

February 24th, 2015 6:44pm

And you have the WMI connection set correctly in the file to connect to the site server?

Free Windows Admin Tool Kit Click here and download it now
February 24th, 2015 10:32pm

Yes

In the file, i configure a server name and Site Code.

set SWbemServices = SWbemLocator.ConnectServer("SMSserver","root\SMS\site_XXX")

February 24th, 2015 10:59pm

Yes, I know this is an old post, but Im trying to clean them up. Did you solve this problem, if so what was the solution?

Free Windows Admin Tool Kit Click here and download it now
March 14th, 2015 10:20am

Since no one has answer this post, I recommend opening  a support case with CSS as they can work with you to solve this problem.

March 28th, 2015 9:30am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics