Skip to main content
OCLC Support

ApplyLocalCDByName

Find the syntax, use, parameters, return values, and an example for the ApplyLocalCDByName macro command in Connexion client.
Syntax BOOL = CS.ApplyLocalCDByName (sName, nOption)
Use to Apply a local constant data record by name to the current record or to records selected in a list.

Same as using the menu command Edit > Constant Data > Local > Apply from List.
Parameters
  • For sName, enter the name of the constant data record you want to apply.
  • For nOption, enter one of the following numbers to indicate which fields to apply:
    • 0 - Fixed field
    • 1 - Variable fields
    • 2 - Both
Return values TRUE if the action is successful, or FALSE if not.
Example Sub Main()

     Dim CS As Object
     Set CS = GetObject(,“Connex.Client”)

     If CS.IsOnline = False Then
          CS.Logon ““, ““, ““
     End If

     CS.Search “WC”, “#1”

     CS.ApplyCDByName “MyCD”, 2


     Dim nSlotNum as Integer
     nSlotNum = CS.SaveToLocalFile (False, False)
     MsgBox “Record saved with “ & nSlotNum & “ slot number”
End Sub

What this example does
  • Logs on to Connexion if not already logged on, using the default authorization and password you selected in Tools > Options > Authorizations tab.
  • Searches WorldCat for record number 1.
  • Applies the local constant data record named MyCD to record number 1.
  • Saves record number 1 to the default bibliographic local save file.
  • Displays the following confirmation message with the local save file number (xxx) assigned to the record: Record saved with xxx slot number.