I want to create a term set using powershell, and i need to pass the term set GUID, as i want to create a copy of our staging term sets inside our live server, so i can export/import managed metadata columns between the 2 farms without any problem. now i find this link which mention how i can create term set using power-shell and pass the term-set name & GUID Link. but when i try to do so using this power-shell script:-
PS C:\Users\spadmin.srv> $termGroup = $termstore.groups["Category"];
PS C:\Users\spadmin.srv> $termSet = $termGroup.CreateTermSet("Customers","af5276
41-**********-5084c17f5ee3")
i got the following exception:-
Cannot convert argument "lcid", with value:
"af5276
41-**********-5084c17f5ee3", for "CreateTermSet" to type
"System.Int32": "Cannot convert value "af5276
41-**********-5084c17f5ee3"
to type "System.Int32". Error: "Input string was not in a correct format.""
At line:1 char:1
+ $termSet =
$termGroup.CreateTermSet("Customers","af5276
41-**********-5084c17f5ee3 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~
+ CategoryInfo : NotSpecified: (:) [], MethodException
+ FullyQualifiedErrorId : MethodArgumentConversionInvalidCastArgument
so can anyone adivce how i can fix this problem? second question. now let say i manage to create the term sets by passing their GUIDs (similar GUIDs which are defined inside our staging server).. so could this cause any problem in the future insdie our live server, if for example i create new term sets using UI,, and the system generate a GUID which already exists.. or this case will never happen??