Thanks. That's exactly what I was looking for.
Nate
-
Nate Smith,
Lead Developer
[EMAIL PROTECTED]
www.doceus.com
-----Original Message-----
From: Roman Maxymchuk [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 8:12 AM
To: Spectra-Talk
Subject: Re: Determining If a Collection Exists?
Read all of the existing collections from the registry and loop over them
<CFSET
Branch="HKEY_LOCAL_MACHINE\SOFTWARE\Allaire\ColdFusion\CurrentVersion\Collec
tions">
<CFREGISTRY ACTION=GETALL Branch="#Branch#"
Type="KEY"
Name="All_Collections">
<!--- Loop over collections. --->
<CFIF Collections.RecordCount GT 0>
<CFLOOP Query="All_Collections">
<CFSET Root = #Branch# & "\" & #Collections.Entry#>
<CFREGISTRY ACTION=GET Branch="#Root#" Entry="TopLevelDirectory"
Type="STRING" VARIABLE="TopLevelDirectory">
<!--- Delete Collections which are meant for SP.CH Search --->
<cfif ListFirst(TopLevelDirectory , "\") eq 'N:'>
<CFCOLLECTION Action="DELETE" Collection="#Collections.Entry#">
</cfif>
</CFLOOP>
</CFIF>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
------------------------------------------------------------------------------
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/spectra_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.