Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Migrating SMS 2.0 content to SMS 2003

0 views
Skip to first unread message

Mikey

unread,
Jan 27, 2005, 5:43:04 PM1/27/05
to
In the midst of migrating our current SMS 2.0 hierarchy to SMS 2003 (side by
side upgrade) and have been dumbstruck that there is no utility to migrate
the SMS 2.0 content to the new SMS 2003 environment. I know I can export /
Import the collections, but found nothing that will bring over the associated
Packages, Avertisements, queries, Etc., etc. etc....

Is this really the case? That I have to manually recreate everything from my
old SMS environment?

Thanks!

Richard Threlkeld <MVP>

unread,
Jan 28, 2005, 1:33:08 AM1/28/05
to
Yeah its a problem. Here's a workaround:

Build a new 2K3 site, upgrade the 2.0 site to 2K3, connect the new 2K3 site
to the former 2.0 (now 2K3) site. Now export the objects from the former
2.0 site will replicate into the new site and then disconnect the site.
Then decommission the old site.

--
Richard Threlkeld
Microsoft MVP - SMS
http://myitforum.techtarget.com/blog/rthrelkeld/


"Mikey" <Mi...@discussions.microsoft.com> wrote in message
news:9AE5FAF1-4885-4B9A...@microsoft.com...

Kim Oppalfens

unread,
Jan 28, 2005, 7:31:55 AM1/28/05
to

Mikey,

If you sent me an email at kimoppalfe...@tiscali.be, I will reply
with a vbs script I created to export package definition files from a
server.

I used this in a test environment to export packages, and reimport them.
If you would like to take if for a test run, I would be more than happy
to sent it to you.

Keep in mind that this has undergone very limited to no testing at all.
Kim
In article <9AE5FAF1-4885-4B9A...@microsoft.com>,
Mi...@discussions.microsoft.com says...

--
Kim Oppalfens
Proud father of Lennart Oppalfens
Since 05/11/2004 08.53 GMT+1

Mikey

unread,
Feb 9, 2005, 7:57:02 PM2/9/05
to
Hey Rich, thanks for the reply, I was wondering how you 'export' the packages
etc, etc, from the upgraded 2.0 box (now 2003) I looked on my current 2003
box and there does not seem to be an option...

Terri

unread,
May 2, 2005, 9:46:02 AM5/2/05
to
I too would like to review the VBS script you mentioned.

We have a location that created an SMS 2003 primary site independent of the
Corporate requirements. We want to create a new SMS site and migrate the
packages and collections of the old environment to the new. I checked
MyITForum but it was for SMS 2.0 PDFs. I wasn't sure if it would be
compatible with SMS 2003.

Thanks for your help
Terri

MSIGUY

unread,
May 30, 2005, 10:47:31 AM5/30/05
to
Terri,

I saw your post regard a script that you created that will export old items
from a SMS 2.0 site to a new SMS 2003 site. I would be forever grateful if
you could share this with me as we are undergoing the same sort of migration
with little to no success.

Thanks

Robert Ronan

Terri

unread,
May 31, 2005, 7:50:02 AM5/31/05
to
I found this VBS Script that seems to work part way. This script will
generate a .SMS file that can then be used to import into SMS (in Packages,
select 'New'| 'Package from Definition'). This script was written for SMS
2.0 but will work for SMS 2003. The only difference is that SMS 2003 will
prompt for source files and source directories even though it is defined in
the .SMS file. I have not found a way to get around this (I already asked
Microsoft if for documentation of the PDF format for SMS 2003, but they only
have one form SMS 2.0). Also, I would like to add logic to the script to
enumerate all the packages and automatically generate the .SMS files.
Currently, the script will export a specified package given the package id.
If you can improve on the script, I would appreciate it.

'///////////////////////////////////////////////////////////////////////////////
'// Export Package to PDF
'// Created by: Brian Howson
'// Usage: change SmsSite and SmsServer to your site and server
'// This script will create a SMS 2.0 .sms file to import somewhere
'// at a different site.
'// useful for moving Packages from site to site
'//
'// You can freely use this script so long as you send me a copy of
'// all PDF's you export with this script to brian....@bbh.com :)
'//
'///////////////////////////////////////////////////////////////////////////////
'
'
'REGEDIT4
'
'[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\NodeTypes\{3AD39FC7-EFD601D0-BDCF-00A0C909FDD7}

\Extensions\SMS_Tools]
'
'[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\NodeTypes\{3AD39FC7-EFD601D0-BDCF-00A0C909FDD7}

\Extensions\SMS_Tools\PDFExport]
'"Name"="PDFExport"
'"Description"="Export Package to PDF"
'"CommandLine"="cscript //NoLogo d:\\download\\wsh\\exppdf.vbs ##SUB:__PATH##"
'
'**Start Encode**


' ##__Path## comes back as:
' \\NJ01TS04\root\sms\site_SDR:SMS_Package.PackageID=SDR0001F

Set objArgs = WScript.Arguments

if (objArgs.count > 0) then
MyPos = InStr(objArgs(0), ":")
SmsPath = Left(objArgs(0), MyPos - 1)
SmsPackage = right(objArgs(0), 8)

else
SmsPath = "\\<servername>\root\sms\site_<site code>"
SmsPackage = "<Package Id>"
end if

Dim Shell
Dim System
Dim oFile
Dim Flags(32)
Set Shell = CreateObject("Wscript.Shell")
Set System = CreateObject("Scripting.FileSystemObject")
Set oFSO = CreateObject("Scripting.FileSystemObject")
Const ForReading = 1
Const ForWriting = 2
CRLF = Chr(13) & Chr(10)

winmgmt1 = "winmgmts:{impersonationLevel=impersonate}!" & _
SmsPath
' SmsServer & "\root\sms\site_" & SmsSite

'///////////////////////////////////////////////////////////////////////////////
'//Echo your connection then get the object
'///////////////////////////////////////////////////////////////////////////////
'// oFile.WriteLine winmgmt1
Set SystemSet = GetObject( winmgmt1 )

'///////////////////////////////////////////////////////////////////////////////
'// Create Query String
'///////////////////////////////////////////////////////////////////////////////
strQuery = "select PackageID, Name, Version, Icon, Description, " & _
"LastRefreshTime, SourceSite, Manufacturer, Language, " & _
"PkgSourceFlag, PkgSourcePath, " & _
"MIFFilename, MIFName, MIFPublisher, MIFVersion from " & _
"SMS_Package where PackageID = '" & SmsPackage & "'"


'///////////////////////////////////////////////////////////////////////////////
'// Create Query Connection
'///////////////////////////////////////////////////////////////////////////////
Set objEnumerator = SystemSet.ExecQuery(strQuery)

'///////////////////////////////////////////////////////////////////////////////
'// Loop through all results and echo to screen
'///////////////////////////////////////////////////////////////////////////////
for each instance in objEnumerator
fname = "D:\temp\" & instance.PackageID &".sms"
' fname = InputBox( "Enter File Name", "Save as...", fname)

Set oFile = System.OpenTextFile(fname, ForWriting, True)
WScript.Echo "Creating " & fname &" for " & instance.Name

oFile.WriteLine ""
oFile.WriteLine "[PDF]"
oFile.WriteLine "VERSION=2.0"
oFile.WriteLine ""
oFile.WriteLine "[Package Definition]"

'// NAME - Required - up to 50 characters
oFile.WriteLine "Name=" & instance.Name

'// VERSION - up to 32 characters
if (len(instance.Version ) > 0) then
oFile.WriteLine "Version=" & instance.Version
end if

'// TODO: ICON comes back as actual Icon data. If the data exists,
'// save in ICO file (?), then put icon file name in value.
'// ICON - file name of icon file (must be in same dir as PDF when you import)
'// Icon returned as an array of Variants
' wscript.echo "Type " & Vartype(instance.icon)
' if (instance.Icon <> NULL) then
' oFile.WriteLine "Icon=" & instance.Icon
' end if

'// PUBLISHER - Required - up to 32 characters
oFile.WriteLine "Publisher=" & instance.Manufacturer

'// LANGUAGE - Required
oFile.WriteLine "Language=" & instance.Language

'// COMMENT - not required, up to 127 charaters
if (len(instance.Description) > 0) then
oFile.WriteLine "Comment=" & instance.Description
end if

'// PkgSourceFlag - not required
oFile.WriteLine "PkgSourceFlag=" & instance.PkgSourceFlag

'// PkgSourcePath - not required
oFile.WriteLine "PkgSourcePath=" & instance.PkgSourcePath

'// MIFFILENAME
if (len(instance.MIFFilename) > 0) then
oFile.WriteLine "MIFfilename=" & instance.MIFFilename
end if

'// MIFNAME
if (len(instance.MIFName) > 0) then
oFile.WriteLine "MIFName=" & instance.MIFName
end if

'// MIFPUBLISHER
if (len(instance.MIFPublisher) > 0) then
oFile.WriteLine "MIFPublisher=" & instance.MIFPublisher
end if

'// MIFVERSION
if (len(instance.MIFVersion) > 0) then
oFile.WriteLine "MIFVersion=" & instance.MIFVersion
end if

'///////////////////////////////////////////////////////////////////////////////
prgQuery = "select PackageID, ProgramName from SMS_Program where PackageID
= '" & _
instance.PackageID & "'"
Set prgEnumerator = SystemSet.ExecQuery(prgQuery)

'///////////////////////////////////////////////////////////////////////////////
'// Create Programs= line by putting program names in comma delimited list
'///////////////////////////////////////////////////////////////////////////////
proglist = ""
for each prog in prgEnumerator
if (len(proglist) > 0) then
proglist = proglist & ", " & prog.ProgramName
else
proglist = prog.ProgramName
end if
next
oFile.WriteLine "Programs=" & proglist

'///////////////////////////////////////////////////////////////////////////////
'// Loop through each program and output parameters
'///////////////////////////////////////////////////////////////////////////////
for each prog in prgEnumerator

set progobj = SystemSet.Get(prog.Path_)

'///////////////////////////////////////////////////////////////////////////////
'// parse ProgramFlags to attributes below
'///////////////////////////////////////////////////////////////////////////////
For loopcounter = 12 To 29 Step 1
If ((progobj.ProgramFlags And 2 ^ loopcounter) = (2 ^ loopcounter))
Then
Flags(loopcounter) = 1
Else
Flags(loopcounter) = 0
End If
Next '// for loopcounter

oFile.WriteLine ""

'// PROGRAMNAME
oFile.WriteLine "[" & progobj.ProgramName & "]"

'// NAME
oFile.WriteLine "Name=" & progobj.ProgramName


'// ICON
' if (len(progobj.Icon) > 0) then
' oFile.WriteLine "Icon=" & progobj.Icon
' end if

'// COMMENT
if (len(progobj.Description) > 0) then
oFile.WriteLine "Comment=" & progobj.Description
end if

'// COMMANDLINE
oFile.WriteLine "CommandLine=" & progobj.CommandLine

'// STARTIN
if (len(progobj.WorkingDirectory) > 0) then
oFile.WriteLine "StartIn=" & progobj.WorkingDirectory
end if

'// RUN - specifies run mode for program
if Flags(22) = 1 then
oFile.WriteLine "Run=Minimized"
elseif Flags(23) = 1 then
oFile.WriteLine "Run=Maximized"
elseif Flags(24) = 1 then
oFile.WriteLine "Run=Hidden"
else
oFile.WriteLine "Run=Normal"
end if

'// AFTERRUNNING - note, if entry missing, no action performed
if Flags(18) = 1 then
oFile.WriteLine "AfterRunning=ProgramRestart"
elseif Flags(19) = 1 then
oFile.WriteLine "AfterRunning=SMSRestart"
elseif Flags(25) = 1 then
oFile.WriteLine "AfterRunning=SMSLogoff"
end if

'// ESTIMATEDDISKSPACE - if entry missing defaults to 'UNKNOWN', include KB
or MB.
if (len(progobj.DiskSpaceReq) > 0) then
oFile.WriteLine "EstimatedDiskSpace=" & progobj.DiskSpaceReq
end if

'// ESDTIMATEDRUNTIME - in minutes, if entry missing defaults to 'UNKNOWN'
if (len(progobj.Duration) > 0) then
oFile.WriteLine "EstimatedRunTime=" & progobj.Duration
end if

'// ENABLERUNTIMEMONITORING - notifies user if time exceeded by 15 minutes
if Flags(28) = 1 then
oFile.WriteLine "EnableRunTimeMonitoring=True"
else
oFile.WriteLine "EnableRunTimeMonitoring=False"
end if

'// ADDITIONALPROGRAMREQUIREMENTS - comment seen by administrators and users
if (len(progobj.Requirements) > 0) then
oFile.WriteLine "AdditionalProgramRequirements=" &
progobj.Requirements
end if

'// CANRUNWHEN - application install dependent on user logged on or not.
if Flags(14) = 1 then
oFile.WriteLine "CanRunWhen=UserLoggedOn"
elseif Flags(17) = 1 then
oFile.WriteLine "CanRunWhen=NoUserLoggedOn"
else
oFile.WriteLine "CanRunWhen=AnyUserStatus"
end if

'// USERINPUTREQUIRED - specify whether user must interact with program
if Flags(14) = 1 then
oFile.WriteLine "UserInputRequired=False"
else
oFile.WriteLine "UserInputRequired=True"
end if

'// ADMINRIGHTSREQUIRED - specify program elevated to administrator
if Flags(15) = 1 then
oFile.WriteLine "AdminRightsRequired=True"
end if

'// USEINSTALLACCOUNT - use Windows NT Client Software installation account
if Flags(26) = 1 then
oFile.WriteLine "UseInstallAccount=True"
end if

'// DRIVELETTERCONNECTION - program requires a drive letter connection to
package share
if Flags(20) = 1 then
oFile.WriteLine "DriveLetterConnection=False"
else
oFile.WriteLine "DriveLetterConnection=True"
end if

'// SPECIFYDRIVE - drive letter to connect as (if DRIVELETTERCONNECTION True)
if (len(progobj.DriveLetter) > 0) then
oFile.WriteLine "SpecifyDrive=" & progobj.DriveLetter
end if

'// RECONNECTDRIVEATLOGON - makes drive connection persistent
if Flags(21) = 1 then
oFile.WriteLine "ReconnectDriveAtLogon=True"
end if

'// DEPENDENTPROGRAM - another program in this package to run first
if (len(progobj.DependentProgram) > 0) then
oFile.WriteLine "DependentProgram=" & progobj.DependentProgram
end if

'// ASSIGNMENT - assign to the first or every user of machine
if Flags(16) = 1 then
oFile.WriteLine "Assignment=EveryUser"
else
oFile.WriteLine "Assignment=FirstUser"
end if

'// DISABLED - Whether program can be run and/or displayed to clients
if Flags(12) = 1 then
oFile.WriteLine "Disabled=True"
end if

'// REMOVEPROGRAM - whether program uninstalled when no longer advertised.
if Flags(29) = 1 then
oFile.WriteLine "RemoveProgram=True"
' requires entry for UninstallKey=
end if

'// UNINSTALLKEY - key containing uninstall information for package
if (len(progobj.RemovalKey) > 0) then
oFile.WriteLine "UninstallKey=" & progobj.RemovalKey
end if

'///////////////////////////////////////////////////////////////////////////////
'// Logic for Platform requirements
'///////////////////////////////////////////////////////////////////////////////
if Flags(27) = 0 then ' Only execute if ANY_PLATFORM(27) is False
progSupp = ""
progPlatform = ""
progMinMax = ""


for each progos in progobj.SupportedOperatingSystems
progPlatform = progos.name & " (" & progos.Platform & ")"
if (Instr(progSupp, progPlatform) = 0) then
if (len(progSupp) > 0) then
progSupp = progSupp & ", "
end if
progSupp = progSupp & progPlatform
progCount = 1
progMinMax = progMinMax & progPlatform & "MinVersion" &
progCount & "=" &

progos.MinVersion & CRLF
progMinMax = progMinMax & progPlatform & "MaxVersion" &
progCount & "=" &

progos.MaxVersion & CRLF
else
progCount = progCount + 1
progMinMax = progMinMax & progPlatform & "MinVersion" &
progCount & "=" &

progos.MinVersion & CRLF
progMinMax = progMinMax & progPlatform & "MaxVersion" &
progCount & "=" &

progos.MaxVersion & CRLF
end if
Next

oFile.WriteLine "SupportedClients=" & progSupp
oFile.WriteLine progMinMax

end if ' ANY_PLATFORM(27)

Next ' program

oFile.WriteLine ""
oFile.WriteLine ""
oFile.WriteLine ""

'// Warning, the next line will refresh the files in your package
'// This is a cool trick for an unattended refresh!
'// RetCode = instance.RefreshPkgSource

oFile.close
Next ' package

Wscript.Quit(0)

Kim Oppalfens

unread,
May 31, 2005, 8:07:21 AM5/31/05
to

Upon Request script to import/export Queries

'///////////////////////////////////////////////////////////////////////
////////
'// Export All Queries to TXT
'// Created by: Kim Oppalfens (MVP SMS)
'///////////////////////////////////////////////////////////////////////
Option Explicit
Dim objArgs, Command, qryfile, Sitecode, strSiteServer
Dim objFSO, WmiQuery, objWmiService, query, colQuery, oFile
Dim Line, queryexpression
Dim qryParameters, newquery

Set objArgs = WScript.Arguments

if (objArgs.count > 2) then
Command = Wscript.arguments.item(0)
Qryfile = Wscript.arguments.item(1)
Sitecode = wscript.arguments.item(2)
If (objArgs.count = 3) then
strSiteServer = "."
Else
strSiteServer = wscript.arguments.item(3)
End If
else
Wscript.echo("Usage: migratequeries.vbs IMPORT|EXPORT20|EXPORT2003
File SITECODE [SITESERVER]")
Wscript.echo("Example: migratequeries.vbs EXPORT2003 c:\expqueries.txt
S01 SMSSVR01")
Wscript.echo("")
Wscript.echo("IMPORT|EXPORT20|Choose whether you want to import or
export queries")
Wscript.echo("EXPORT2003, EXPORT20 will export to format for
reimporting to sms 2.0")
Wscript.echo(" EXPORT2003 will export to format for
reimporting to sms 2003")
Wscript.echo("File, Filename of the textfile where to
import/export queries")
Wscript.echo(" to/from")
Wscript.echo("SITECODE, 3-char SMS sitecode of the site for which you
want to ")
Wscript.echo(" import/export queries")
Wscript.echo("SITESERVER, Name of the SMS siteserver you want to
export packages from.")
Wscript.echo(" Default is Local Server")
Wscript.Quit(1)
end if


Set objFSO = Createobject ("Scripting.filesystemobject")

If ucase(command) = "EXPORT20" OR ucase(command) = "EXPORT2003" Then
WmiQuery = "select * from sms_query where limittocollectionid = " & CHR
(34) & CHR(34) & _
"And queryid like " & CHR(34) & sitecode & "%" & CHR(34)
Set objWMIService = GetObject ("Winmgmts:
{impersonationlevel=impersonate}!\\" & _
strSiteServer & "\root\sms\site_" & sitecode)

Set colquery = objWMIService.Execquery(wmiQuery)
Set oFile = objFSO.CreateTextFile(qryfile,TRUE)

For Each query in colquery
If ucase(command) = "EXPORT20" Then
queryexpression = query.Expression
Else
queryexpression = replace
(query.Expression,"SMS_G_System_ADDREMPROGS","SMS_G_System_ADD_REMOVE_PR
OGRAMS")
End If

line = query.name & ";" & _
query.comments & ";" & _
query.limittocollectionid & ";" & _
query.TargetClassname & ";" & _
queryexpression
Wscript.echo line
ofile.WriteLine Line
Next
ofile.close
End If

If ucase(command) = "IMPORT" Then
set objfso = Createobject ("Scripting.filesystemobject")
Set ofile = objfso.opentextfile (qryfile,1)
Set objWMIService = GetObject ("Winmgmts:
{impersonationlevel=impersonate}!\\" & _
strSiteServer & "\root\sms\site_" & sitecode)

Do While NOT ofile.atendofstream
line = ofile.readline
QryParameters = Split (line,";",-1,1)
Set newquery = objWMIService.get("SMS_Query").SpawnInstance_()
newquery.name = Qryparameters(0)
newquery.comments = Qryparameters(1)
newquery.limittocollectionid = Qryparameters(2)
newquery.TargetClassname = Qryparameters(3)
newquery.Expression = Qryparameters(4)
newquery.put_
WScript.echo newquery.name & " was imported"
Loop
ofile.close
End if

In article <35D9B539-638D-4AF3...@microsoft.com>,
Te...@discussions.microsoft.com says...

--
Kim Oppalfens
SMS MVP

Kim Oppalfens

unread,
May 31, 2005, 8:05:30 AM5/31/05
to

Upon Request:

'///////////////////////////////////////////////////////////////////////
////////
'// Export Packages to PDF
'// This script will create SMS 2.0 .sms files to import somewhere

'// at a different site.
'//

'// Created by: Brian Howson

'// Modified by Kim Oppalfens (MVP SMS)
'///////////////////////////////////////////////////////////////////////
////////
'
'
Dim Shell
Dim strSiteServer


Dim System
Dim oFile
Dim Flags(32)

Dim starttime


Set Shell = CreateObject("Wscript.Shell")
Set System = CreateObject("Scripting.FileSystemObject")
Set oFSO = CreateObject("Scripting.FileSystemObject")
Const ForReading = 1
Const ForWriting = 2
CRLF = Chr(13) & Chr(10)

Set objArgs = WScript.Arguments

if (objArgs.count > 0) then
Sitecode = wscript.arguments.item(0)
If (objArgs.count = 1) then
strSiteServer = "."
Else
strSiteServer = wscript.arguments.item(1)
End If
else
Wscript.echo("Usage: exportpkg.vbs SITECODE [SITESERVER]")
Wscript.echo("Example: exportpkg.vbs S01 SMSSVR01")
Wscript.echo("")
Wscript.echo("SITECODE, 3-char SMS sitecode of the site you want to
export packages")
Wscript.echo(" from.")


Wscript.echo("SITESERVER, Name of the SMS siteserver you want to
export packages from.")
Wscript.echo(" Default is Local Server")
Wscript.Quit(1)
end if

winmgmt1 = "winmgmts:\\" & strSiteServer & "\root\sms\site_" & sitecode
pkgcount = 0


'///////////////////////////////////////////////////////////////////////


////////
'//Echo your connection then get the object
'///////////////////////////////////////////////////////////////////////
////////

Set SystemSet = GetObject( winmgmt1 )

'///////////////////////////////////////////////////////////////////////
////////
'// Create Query String
'///////////////////////////////////////////////////////////////////////
////////

strQuery = "select PackageID, Name, Version, Icon, Description, " & _
"LastRefreshTime, SourceSite, Manufacturer, Language, " & _

"MIFFilename, MIFName, MIFPublisher, MIFVersion from

SMS_Package "


'///////////////////////////////////////////////////////////////////////
////////
'// Create Query Connection
'///////////////////////////////////////////////////////////////////////
////////
Starttime = Time
Set objEnumerator = SystemSet.ExecQuery(strQuery)

'///////////////////////////////////////////////////////////////////////


////////
'// Loop through all results and echo to screen
'///////////////////////////////////////////////////////////////////////
////////

foldername = InputBox( "Enter Folder Name eg c:\pdffiles ", "Save
as...", foldername)

for each instance in objEnumerator

fname = foldername &"\"& instance.PackageID &".sms"

Set oFile = System.OpenTextFile(fname, ForWriting, True)
WScript.Echo "Creating " & fname &" for " & instance.Name

oFile.WriteLine ""
oFile.WriteLine "[PDF]"
oFile.WriteLine "VERSION=2.0"
oFile.WriteLine ""
oFile.WriteLine "[Package Definition]"

'// NAME - Required - up to 50 characters
oFile.WriteLine "Name=" & instance.Name

'// VERSION - up to 32 characters
if (len(instance.Version ) > 0) then
oFile.WriteLine "Version=" & instance.Version
end if

'// TODO: ICON comes back as actual Icon data. If the data exists,
'// save in ICO file (?), then put icon file name in value.
'// ICON - file name of icon file (must be in same dir as PDF when you
import)
'// Icon returned as an array of Variants
' wscript.echo "Type " & Vartype(instance.icon)
' if (instance.Icon <> NULL) then
' oFile.WriteLine "Icon=" & instance.Icon
' end if

'// PUBLISHER - Required - up to 32 characters

if (len(instance.Manufacturer) = 0) then
oFile.WriteLine "Publisher=unknown"
Else
oFile.WriteLine "Publisher=" & instance.Manufacturer
end if


'// LANGUAGE - Required
if (len(instance.Language) = 0) then
oFile.WriteLine "Language=English"
Else
oFile.WriteLine "Language=" & instance.Language
end if

'// COMMENT - not required, up to 127 charaters
if (len(instance.Description) > 0) then
oFile.WriteLine "Comment=" & instance.Description
end if

'// MIFFILENAME

set progobj = SystemSet.Get(prog.Path_)

oFile.WriteLine ""

'// COMMENT
if (len(progobj.Comment) > 0) then
oFile.WriteLine "Comment=" & progobj.Comment
end if

if Flags(13) = 1 then

oFile.WriteLine ""
oFile.WriteLine ""
oFile.WriteLine ""

oFile.close
pkgcount = pkgcount +1
Next ' package

Wscript.echo "Started at: " & starttime
Endtime = Time
Wscript.echo "Stopped at:" & endtime
line = DateDiff("s",starttime,endtime)
Wscript.echo "Exported " & pkgcount & " packages in " & line & "
Seconds"

Wscript.Quit(0)

--
Kim Oppalfens
SMS MVP

MSIGUY

unread,
May 31, 2005, 9:20:08 AM5/31/05
to
Thanks to both of you,

Do you know of any progamatic way of exporting and importing collections or
adverts

Kim Oppalfens

unread,
May 31, 2005, 10:21:16 AM5/31/05
to

Adverts are fairly simple modifying the query script to adverts
shouldn't take anyone with basic scripting knowledge and access to the
sms sms 2003 sdk any longer than half an hour. Unfortunately I am going
to be terribly busy in the next 2 weeks. So either someone will have to
modify this code or you will have to wait for a while.

Collections are trikier since you can't recreating the collection
memberships for direct membership collections until all clients have
been migrated. Query based collections should be feasible.

Kim Oppalfens
MVP SMS
In article <2FE620E1-623B-425B...@microsoft.com>,
MSI...@discussions.microsoft.com says...

--
Kim Oppalfens
SMS MVP

0 new messages