'MacroName:AddCommon34X 'MacroDescription:Add 34X fields using an interactive dialog box 'Macro created by: Joel Hahn, Cooperative Computer Services 'Macro last modified: 22 Dec 2016 Option Explicit Option Base 1 Declare Function DlgFunc34XEntry( WhichControl$, action%, suppvalue& ) As Integer Dim OutputList$() Dim PointSizeList$() Dim CDSoundChannels$() Dim CDSpecialCharList$() Dim VideoSoundChannels$() Dim VideoSpecialCharList$() Dim Broadcast$() Dim DVDRegions$() Dim BluRayRegions$() Dim RPMList$() Dim GrooveList$() Dim DiameterList$() Sub Main Dim j Dim bool Dim CS As Object On Error Resume Next Set CS = GetObject(,"Connex.Client") On Error GoTo 0 If CS Is Nothing Then Set CS = CreateObject("Connex.Client") End If ReDim OutputList$(1) Dim FormatList$(9) FormatList$(1) = "Select format" : FormatList$(2) = "Blu-ray" : FormatList$(3) = "CD" : FormatList$(4) = "DVD" : FormatList$(5) = "Large/Giant Print" FormatList$(6) = "Playaway" : FormatList$(7) = "Playaway View" : FormatList$(8) = "Record" : FormatList$(9) = "VHS" ReDim PointSizeList$(16) PointSizeList$(1) = " " : PointSizeList$(2) = "12" : PointSizeList$(3) = "13" : PointSizeList$(4) = "14" : PointSizeList$(5) = "15" : PointSizeList$(6) = "16" PointSizeList$(7) = "17" : PointSizeList$(8) = "18" : PointSizeList$(9) = "20" : PointSizeList$(10) = "22" : PointSizeList$(11) = "24" PointSizeList$(12) = "26" : PointSizeList$(13) = "28" : PointSizeList$(14) = "36" : PointSizeList$(15) = "48" : PointSizeList$(16) = "72" ReDim CDSoundChannels$(4) CDSoundChannels$(1) = "not specified" : CDSoundChannels$(2) = "mono" : CDSoundChannels$(3) = "stereo" : CDSoundChannels$(4) = "quadraphonic" ReDim CDSpecialCharList$(9) CDSpecialCharList$(1) = "Dolby" : CDSpecialCharList$(2) = "Dolby-A encoded" : CDSpecialCharList$(3) = "Dolby-B encoded" : CDSpecialCharList$(4) = "Dolby-C encoded" CDSpecialCharList$(5) = "Digital recording" : CDSpecialCharList$(6) = "dbx encoded" : CDSpecialCharList$(7) = "NAB standard" CDSpecialCharList$(8) = "CCIR standard" : CDSpecialCharList$(9) = "CX encoded" ReDim VideoSoundChannels$(4) VideoSoundChannels$(1) = "not specified" : VideoSoundChannels$(2) = "mono" : VideoSoundChannels$(3) = "stereo" : VideoSoundChannels$(4) = "surround" ReDim VideoSpecialCharList$(9) VideoSpecialCharList$(1) = "Dolby" : VideoSpecialCharList$(2) = "Dolby-A encoded" : VideoSpecialCharList$(3) = "Dolby-B encoded" VideoSpecialCharList$(4) = "Dolby-C encoded" : VideoSpecialCharList$(5) = "Dolby digital 2.0" : VideoSpecialCharList$(6) = "Dolby digital 5.1" VideoSpecialCharList$(7) = "Dolby digital 7.1" : VideoSpecialCharList$(8) = "Dolby digital" : VideoSpecialCharList$(9) = "DTS-HDMA" ReDim Broadcast$(5) Broadcast$(1) = "not specified" : Broadcast$(2) = "NTSC" : Broadcast$(3) = "PAL" : Broadcast$(4) = "SECAM" : Broadcast$(5) = "HDTV" ReDim DVDRegions$(12) DVDRegions$(1) = "not specified" : DVDRegions$(2) = "1" : DVDRegions$(3) = "2" : DVDRegions$(4) = "3" : DVDRegions$(5) = "4" : DVDRegions$(6) = "5" DVDRegions$(7) = "6" : DVDRegions$(8) = "7" : DVDRegions$(9) = "8" : DVDRegions$(10) = "9" : DVDRegions$(11) = "0" : DVDRegions$(12) = "all" ReDim BluRayRegions$(9) BluRayRegions$(1) = "not specified" : BluRayRegions$(2) = "A" : BluRayRegions$(3) = "B" : BluRayRegions$(4) = "C" : BluRayRegions$(5) = "1" BluRayRegions$(6) = "2" : BluRayRegions$(7) = "3" : BluRayRegions$(8) = "0" : BluRayRegions$(9) = "all" ReDim RPMList$(5) RPMList$(1) = "33 1/3" : RPMList$(2) = "45" : RPMList$(3) = "78" : RPMList$(4) = "16" : RPMList$(5) = "8" ReDim GrooveList$(3) GrooveList$(1) = "not specified" : GrooveList$(2) = "microgroove (fine)" : GrooveList$(3) = "coarse groove (standard)" ReDim DiameterList$(7) DiameterList$(1) = "12 in." : DiameterList$(2) = "3 in." : DiameterList$(3) = "5 in." : DiameterList$(4) = "7 in." : DiameterList$(5) = "10 in." : DiameterList$(6) = "16 in." : DiameterList$(7) = "Other" Begin Dialog newdlg2 299, 265,"Add 34X Fields", .DlgFunc34XEntry DropListBox 5, 5, 72, 89, FormatList$(), .Format 'Book GroupBox 5, 25, 285, 90, "Book", .BookGroup OptionGroup .TypeSize OptionButton 15, 35, 60, 10, "Large Print", .LargePrint OptionButton 80, 35, 55, 10, "Giant Print", .GiantPrint Text 10, 52, 45, 15, "Point size:", .PointSizeLabel DropComboBox 50, 50, 65, 72, PointSizeList$(), .PointSize 'CD GroupBox 5, 25, 285, 90, "CD", .CDGroup Text 10, 37, 35, 9, "Channels:", .CDChannelsLabel DropListBox 90, 35, 65, 51, CDSoundChannels$(), .CDSoundChannels Text 10, 52, 75, 15, "Special characteristics:", .CDSpecialCharLabel DropComboBox 90, 50, 87, 108, CDSpecialCharList$(), .CDSpecialChar 'DVD / Blu-ray / VHS shared fields Text 10, 37, 35, 9, "Channels:", .VideoChannelsLabel DropListBox 90, 35, 65, 51, VideoSoundChannels$(), .VideoSoundChannels Text 10, 52, 75, 10, "Special characteristics:", .VideoSpecialCharLabel DropComboBox 90, 50, 88, 108, VideoSpecialCharList$(), .VideoSpecialChar Text 10, 67, 65, 10, "Broadcast standard:", .BroadcastLabel DropListBox 90, 65, 65, 56, Broadcast$(), .Broadcast 'DVD GroupBox 5, 25, 285, 90, "DVD", .DVDGroup Text 10, 82, 30, 10, "Regions:", .DVDRegionsLabel DropListBox 90, 80, 65, 120, DVDRegions$(), .DVDRegions 'Blu-ray GroupBox 5, 25, 285, 90, "Blu-ray", .BluRayGroup 'Text 10, 35, 35, 9, "Channels:", .VideoChannelsLabel 'DropListBox 45, 35, 70, 51, VideoSoundChannels$(), .VideoSoundChannels 'Text 120, 35, 75, 10, "Special characteristics:", .VideoSpecialCharLabel 'DropComboBox 200, 35, 89, 108, VideoSpecialCharList$(), .VideoSpecialChar 'Text 125, 50, 65, 10, "Broadcast standard:", .BroadcastLabel 'DropListBox 200, 50, 88, 56, Broadcast$(), .Broadcast Text 10, 82, 30, 10, "Regions:", .BluRayRegionsLabel DropListBox 90, 80, 65, 108, BluRayRegions$(), .BluRayRegions 'VHS GroupBox 5, 25, 285, 90, "VHS", .VHSGroup 'Text 10, 35, 35, 9, "Channels:", .VideoChannelsLabel 'DropListBox 45, 35, 70, 51, VideoSoundChannels$(), .VideoSoundChannels 'Text 120, 35, 75, 10, "Special characteristics:", .VideoSpecialCharLabel 'DropComboBox 200, 35, 89, 71, VideoSpecialCharList$(), .VideoSpecialChar 'Text 125, 50, 65, 10, "Broadcast standard:", .BroadcastLabel 'DropListBox 200, 50, 88, 56, Broadcast$(), .Broadcast 'CheckBox 15, 100, 60, 9, "Add default $3", .MaterialSpec 'Playaway GroupBox 5, 25, 285, 90, "Playaway", .PlayawayGroup 'Text 10, 60, 35, 9, "Channels:", .CDChannelsLabel 'DropComboBox 50, 60, 70, 51, "mono"+chr$(9)+"stereo"+chr$(9)+"quadraphonic", .CDSoundChannels 'Text 120, 35, 75, 10, "Special characteristics:", .CDSpecialCharLabel 'DropComboBox 200, 35, 87, 71, "Dolby-A encoded"+chr$(9)+"Dolby-B encoded"+chr$(9)+"Dolby-C encoded"+chr$(9)+"Digital recording"+chr$(9)+"dbx encoded"+chr$(9)+"NAB standard"+chr$(9)+"CCIR standard"+chr$(9)+"CX encoded", .CDSpecialChar 'Playaway View GroupBox 5, 25, 285, 90, "Playaway View", .PlayawayViewGroup 'Text 10, 60, 35, 9, "Channels:", .ChannelsLabel 'DropComboBox 50, 60, 70, 51, "mono"+chr$(9)+"stereo"+chr$(9)+"quadraphonic", .SoundChannels 'Text 120, 35, 75, 10, "Special characteristics:", .CDSpecialCharLabel 'DropComboBox 200, 35, 87, 71, "Dolby-A encoded"+chr$(9)+"Dolby-B encoded"+chr$(9)+"Dolby-C encoded"+chr$(9)+"Digital recording"+chr$(9)+"dbx encoded"+chr$(9)+"NAB standard"+chr$(9)+"CCIR standard"+chr$(9)+"CX encoded", .CDSpecialChar 'Record GroupBox 5, 25, 285, 90, "Record", .RecordGroup Text 10, 37, 20, 10, "RPM:", .RPMLabel DropListBox 90, 35, 69, 60, RPMList$(), .RPM Text 10, 52, 35, 9, "Channels:", .RecordChannelsLabel DropListBox 90, 50, 70, 51, CDSoundChannels$(), .RecordSoundChannels Text 10, 67, 65, 10, "Groove width/pitch:", .GrooveLabel DropListBox 90, 65, 85, 48, GrooveList$(), .Groove Text 10, 82, 30, 10, "Diamter:", .DiameterLabel DropListBox 90, 80, 37, 84, DiameterList$(), .Diameter 'Map ' 'GroupBox 5, 25, 285, 90, "Map", .MapGroup ' 'PushButton 15, 247, 50, 15, "Re&move" ' 'CheckBox 15, 100, 60, 9, "Add default $3", .MaterialSpec 'Art ' 'GroupBox 5, 25, 285, 90, "Map", .MapGroup ' 'PushButton 15, 247, 50, 15, "Re&move" ' 'CheckBox 15, 100, 60, 9, "Add default $3", .MaterialSpec CheckBox 15, 100, 60, 9, "Add default $3", .MaterialSpec PushButton 15, 120, 50, 15, "Add to &List", .AddToList ListBox 5, 145, 285, 100, OutputList$(), .SampleOutput PushButton 15, 247, 50, 15, "Re&move", .RemoveFromList PushButton 70, 247, 50, 15, "&Clear List", .ClearList PushButton 235, 120, 20, 15, "&Help", .Help OkButton 180, 247, 50, 15 CancelButton 235, 247, 50, 14 '#, 120 End Dialog Dim ChangeInfo as newdlg2 Dim retval retval = Dialog (ChangeInfo) If retval = 0 then Goto Done '***Note: -1 = OK, 0 = Cancel, 1 = AddToList, 2 = RemoveFromList If retval = -1 Then If OutputList$(1) <> "" Then j = 1 Do While j <= UBound(OutputList$) bool = CS.AddField(999, OutputList$(j)) 'MsgBox OutputList$(j) j = j + 1 Loop End If End If Done: End Sub Function DlgFunc34XEntry( WhichControl$, action%, suppvalue& ) As Integer Dim TmpOutput$ Dim MaterialSpec$(0 to 1) Dim m, n dim place Select Case action% Case 1 ' set up initial values displayed in dialog box 'DlgValue("PointSize"), 3 'DlgValue("DVDRegions"), 1 'DlgValue("BluRayRegions"), 1 DlgVisible "MaterialSpec", 0 DlgEnable "BookGroup", 0 DlgEnable "PointSizeLabel", 0 DlgEnable "PointSize", 0 DlgEnable "TypeSize", 0 DlgVisible "BookGroup", 0 DlgVisible "PointSizeLabel", 0 DlgVisible "PointSize", 0 DlgVisible "TypeSize", 0 DlgEnable "CDGroup", 0 DlgEnable "CDChannelsLabel", 0 DlgEnable "CDSoundChannels", 0 DlgEnable "CDSpecialChar", 0 DlgEnable "CDSpecialCharLabel", 0 DlgVisible "CDGroup", 0 DlgVisible "CDChannelsLabel", 0 DlgVisible "CDSoundChannels", 0 DlgVisible "CDSpecialChar", 0 DlgVisible "CDSpecialCharLabel", 0 DlgEnable "DVDGroup", 0 DlgEnable "VideoChannelsLabel", 0 DlgEnable "VideoSoundChannels", 0 DlgEnable "VideoSpecialCharLabel", 0 DlgEnable "VideoSpecialChar", 0 DlgEnable "BroadcastLabel", 0 DlgEnable "Broadcast", 0 DlgEnable "DVDRegionsLabel", 0 DlgEnable "DVDRegions", 0 DlgVisible "DVDGroup", 0 DlgVisible "VideoChannelsLabel", 0 DlgVisible "VideoSoundChannels", 0 DlgVisible "VideoSpecialCharLabel", 0 DlgVisible "VideoSpecialChar", 0 DlgVisible "BroadcastLabel", 0 DlgVisible "Broadcast", 0 DlgVisible "DVDRegionsLabel", 0 DlgVisible "DVDRegions", 0 DlgEnable "BluRayGroup", 0 DlgEnable "BluRayRegions", 0 DlgEnable "BluRayRegionsLabel", 0 DlgVisible "BluRayGroup", 0 DlgVisible "BluRayRegionsLabel", 0 DlgVisible "BluRayRegions", 0 DlgEnable "VHSGroup", 0 DlgVisible "VHSGroup", 0 DlgEnable "PlayawayGroup", 0 DlgVisible "PlayawayGroup", 0 DlgEnable "PlayawayViewGroup", 0 DlgVisible "PlayawayViewGroup", 0 DlgEnable "RecordGroup", 0 DlgEnable "RPMLabel", 0 DlgEnable "RPM", 0 DlgEnable "GrooveLabel", 0 DlgEnable "Groove", 0 DlgEnable "DiameterLabel", 0 DlgEnable "Diameter", 0 DlgEnable "RecordChannelsLabel", 0 DlgEnable "RecordSoundChannels", 0 DlgVisible "RecordGroup", 0 DlgVisible "RPMLabel", 0 DlgVisible "RPM", 0 DlgVisible "GrooveLabel", 0 DlgVisible "Groove", 0 DlgVisible "DiameterLabel", 0 DlgVisible "Diameter", 0 DlgVisible "RecordChannelsLabel", 0 DlgVisible "RecordSoundChannels", 0 Case 2 ' what to do if button or control value was changed (by clicking it) Select Case WhichControl$ Case "Format" DlgEnable "BookGroup", 0 DlgEnable "PointSizeLabel", 0 DlgEnable "PointSize", 0 DlgEnable "TypeSize", 0 DlgVisible "BookGroup", 0 DlgVisible "PointSizeLabel", 0 DlgVisible "PointSize", 0 DlgVisible "TypeSize", 0 DlgVisible "MaterialSpec", 0 DlgEnable "CDGroup", 0 DlgEnable "CDChannelsLabel", 0 DlgEnable "CDSoundChannels", 0 DlgEnable "CDSpecialChar", 0 DlgEnable "CDSpecialCharLabel", 0 DlgVisible "CDGroup", 0 DlgVisible "CDChannelsLabel", 0 DlgVisible "CDSoundChannels", 0 DlgVisible "CDSpecialChar", 0 DlgVisible "CDSpecialCharLabel", 0 DlgEnable "DVDGroup", 0 DlgEnable "VideoChannelsLabel", 0 DlgEnable "VideoSoundChannels", 0 DlgEnable "VideoSpecialCharLabel", 0 DlgEnable "VideoSpecialChar", 0 DlgEnable "BroadcastLabel", 0 DlgEnable "Broadcast", 0 DlgEnable "DVDRegionsLabel", 0 DlgEnable "DVDRegions", 0 DlgVisible "DVDGroup", 0 DlgVisible "VideoChannelsLabel", 0 DlgVisible "VideoSoundChannels", 0 DlgVisible "VideoSpecialCharLabel", 0 DlgVisible "VideoSpecialChar", 0 DlgVisible "BroadcastLabel", 0 DlgVisible "Broadcast", 0 DlgVisible "DVDRegionsLabel", 0 DlgVisible "DVDRegions", 0 DlgEnable "BluRayGroup", 0 DlgEnable "BluRayRegionsLabel", 0 DlgEnable "BluRayRegions", 0 DlgVisible "BluRayGroup", 0 DlgVisible "BluRayRegionsLabel", 0 DlgVisible "BluRayRegions", 0 DlgEnable "VHSGroup", 0 DlgVisible "VHSGroup", 0 DlgEnable "PlayawayGroup", 0 DlgVisible "PlayawayGroup", 0 DlgEnable "PlayawayViewGroup", 0 DlgVisible "PlayawayViewGroup", 0 DlgEnable "RecordGroup", 0 DlgEnable "RPMLabel", 0 DlgEnable "RPM", 0 DlgEnable "GrooveLabel", 0 DlgEnable "Groove", 0 DlgEnable "DiameterLabel", 0 DlgEnable "Diameter", 0 DlgEnable "RecordChannelsLabel", 0 DlgEnable "RecordSoundChannels", 0 DlgVisible "RecordGroup", 0 DlgVisible "RPMLabel", 0 DlgVisible "RPM", 0 DlgVisible "GrooveLabel", 0 DlgVisible "Groove", 0 DlgVisible "DiameterLabel", 0 DlgVisible "Diameter", 0 DlgVisible "RecordChannelsLabel", 0 DlgVisible "RecordSoundChannels", 0 Select Case DlgValue("Format") Case 0 'Default "select an option" entry Exit Function Case 1 'Blu-ray DlgVisible "MaterialSpec", 1 DlgEnable "BluRayGroup", 1 DlgEnable "VideoChannelsLabel", 1 DlgEnable "VideoSoundChannels", 1 DlgEnable "VideoSpecialCharLabel", 1 DlgEnable "VideoSpecialChar", 1 DlgEnable "BroadcastLabel", 1 DlgEnable "Broadcast", 1 DlgEnable "BluRayRegionsLabel", 1 DlgEnable "BluRayRegions", 1 DlgVisible "BluRayGroup", 1 DlgVisible "VideoChannelsLabel", 1 DlgVisible "VideoSoundChannels", 1 DlgVisible "VideoSpecialCharLabel", 1 DlgVisible "VideoSpecialChar", 1 DlgVisible "BroadcastLabel", 1 DlgVisible "Broadcast", 1 DlgVisible "BluRayRegionsLabel", 1 DlgVisible "BluRayRegions", 1 DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 DlgValue "BluRayRegions", 0 Case 2 'CD DlgEnable "CDGroup", 1 DlgEnable "CDChannelsLabel", 1 DlgEnable "CDSoundChannels", 1 DlgEnable "CDSpecialChar", 1 DlgEnable "CDSpecialCharLabel", 1 DlgVisible "CDGroup", 1 DlgVisible "CDChannelsLabel", 1 DlgVisible "CDSoundChannels", 1 DlgVisible "CDSpecialChar", 1 DlgVisible "CDSpecialCharLabel", 1 DlgVisible "MaterialSpec", 1 DlgValue "CDSoundChannels", 0 DlgText "CDSpecialChar", "" Case 3 'DVD DlgVisible "MaterialSpec", 1 DlgEnable "DVDGroup", 1 DlgEnable "VideoChannelsLabel", 1 DlgEnable "VideoSoundChannels", 1 DlgEnable "VideoSpecialCharLabel", 1 DlgEnable "VideoSpecialChar", 1 DlgEnable "BroadcastLabel", 1 DlgEnable "Broadcast", 1 DlgEnable "DVDRegionsLabel", 1 DlgEnable "DVDRegions", 1 DlgVisible "DVDGroup", 1 DlgVisible "VideoChannelsLabel", 1 DlgVisible "VideoSoundChannels", 1 DlgVisible "VideoSpecialCharLabel", 1 DlgVisible "VideoSpecialChar", 1 DlgVisible "BroadcastLabel", 1 DlgVisible "Broadcast", 1 DlgVisible "DVDRegionsLabel", 1 DlgVisible "DVDRegions", 1 DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 DlgValue "DVDRegions", 0 Case 4 'Large/Giant Print DlgEnable "BookGroup", 1 DlgEnable "TypeSize", 1 DlgEnable "PointSizeLabel", 1 DlgEnable "PointSize", 1 DlgVisible "BookGroup", 1 DlgVisible "TypeSize", 1 DlgVisible "PointSizeLabel", 1 DlgVisible "PointSize", 1 DlgVisible "MaterialSpec", 1 DlgValue "TypeSize", 0 DlgText "PointSize", "" Case 5 'Playaway DlgVisible "MaterialSpec", 1 DlgEnable "PlayawayGroup", 1 DlgVisible "PlayawayGroup", 1 DlgEnable "CDChannelsLabel", 1 DlgEnable "CDSoundChannels", 1 DlgEnable "CDSpecialChar", 1 DlgEnable "CDSpecialCharLabel", 1 DlgVisible "CDChannelsLabel", 1 DlgVisible "CDSoundChannels", 1 DlgVisible "CDSpecialChar", 1 DlgVisible "CDSpecialCharLabel", 1 DlgValue "CDSoundChannels", 0 DlgText "CDSpecialChar", "" Case 6 'Playaway View DlgVisible "MaterialSpec", 1 DlgEnable "PlayawayViewGroup", 1 DlgVisible "PlayawayViewGroup", 1 Case 7 'Record DlgVisible "MaterialSpec", 1 DlgEnable "RecordGroup", 1 DlgEnable "RPMLabel", 1 DlgEnable "RPM", 1 DlgEnable "GrooveLabel", 1 DlgEnable "Groove", 1 DlgEnable "DiameterLabel", 1 DlgEnable "Diameter", 1 DlgVisible "RecordGroup", 1 DlgVisible "RPMLabel", 1 DlgVisible "RPM", 1 DlgVisible "GrooveLabel", 1 DlgVisible "Groove", 1 DlgVisible "DiameterLabel", 1 DlgVisible "Diameter", 1 DlgEnable "RecordChannelsLabel", 1 DlgEnable "RecordSoundChannels", 1 DlgVisible "RecordChannelsLabel", 1 DlgVisible "RecordSoundChannels", 1 DlgValue "RPM", 0 DlgValue "Groove", 0 DlgValue "Diameter", 0 Case 8 'VHS DlgVisible "MaterialSpec", 1 DlgEnable "VHSGroup", 1 DlgEnable "VideoChannelsLabel", 1 DlgEnable "VideoSoundChannels", 1 DlgEnable "VideoSpecialCharLabel", 1 DlgEnable "VideoSpecialChar", 1 DlgEnable "BroadcastLabel", 1 DlgEnable "Broadcast", 1 DlgVisible "VHSGroup", 1 DlgVisible "VideoChannelsLabel", 1 DlgVisible "VideoSoundChannels", 1 DlgVisible "VideoSpecialCharLabel", 1 DlgVisible "VideoSpecialChar", 1 DlgVisible "BroadcastLabel", 1 DlgVisible "Broadcast", 1 DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 End Select Case "Help" DlgFunc34XEntry = TRUE Select Case DlgValue("Format") Case 0 'Default "select an option" entry MsgBox "Select a format in the top dropdown box. Choose the values you need in the fields that appear, then click Add To List. The results will appear in the lower box, with subfield delimiters appearing as ß." & Chr(10) & Chr(10) & "Then select a different format and repeat the process to add fields for any accompanying formats, such as a CD with accompanying DVD." & Chr(10) & Chr(10) & "Select a line in the lower box and click Remove to delete it, or click Clear List to delete everything from the lower box." & Chr(10) & Chr(10) & "Click OK to add the lines from the lower box to the current bibliographic record.",,"Help" Case 1 'Blu-ray MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified or blank, as appropriate." & Chr(10) & Chr(10) & "If none of the Special Characteristics correspond to what's on the item, you can enter your own value in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 2 'CD MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified or blank, as appropriate." & Chr(10) & Chr(10) & "If none of the Special Characteristics correspond to what's on the item, you can enter your own value in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 3 'DVD MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified or blank, as appropriate." & Chr(10) & Chr(10) & "If none of the Special Characteristics correspond to what's on the item, you can enter your own value in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 4 'Large/Giant print" MsgBox "Select Large or Giant print. If the item specifies the point size, you may optionally select it from the list; if the number does not appear on the list, you may enter it in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 5 'Playaway MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified or blank, as appropriate." & Chr(10) & Chr(10) & "If none of the Special Characteristics correspond to what's on the item, you can enter your own value in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 6 'Playaway View MsgBox "The fields added for Playaway View are always the same, so there are no fields here from which to select values; just click the Add to List button." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 7 'Record MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." Case 8 'VHS MsgBox "Select the values in these fields that correspond to what is specified on the item. If the item in hand doesn't specify a value, then leave the field as Not Specified or blank, as appropriate." & Chr(10) & Chr(10) & "If none of the Special Characteristics correspond to what's on the item, you can enter your own value in the box." & Chr(10) & Chr(10) & "Check the Add Default $3 box to prepend a $3 with the basic format type to any fields added to the lower list for the current format." End Select Case "AddToList" '*** Need to also blank out DlgValue for all relevant fields except for the $3 option DlgFunc34XEntry = TRUE TmpOutput$ = "" Select Case DlgValue("Format") Case 0 'Default "select an option" entry Exit Function Case 1 'Blu-ray MaterialSpec$(1) = Chr(223) & "3 Blu-ray: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 3) Else ReDim Preserve OutputList$(3) End If TmpOutput$ = "340 " & Left(MaterialSpec$(DlgValue("MaterialSpec")), 12) & "ßb 4 3/4 in. ß2 rda" OutputList$(UBound(OutputList$) - 2) = TmpOutput$ TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "digital ßb optical" If DlgValue("VideoSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & VideoSoundChannels$(DlgValue("VideoSoundChannels") + 1) End If If DlgText("VideoSpecialChar") <> "" Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "h " & DlgText("VideoSpecialChar") End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ If DlgValue("Broadcast") > 0 Then ReDim Preserve OutputList$(UBound(OutputList$) + 1) TmpOutput$ = "346 " & Left(MaterialSpec$(DlgValue("MaterialSpec")), 12) & "ßb " & Broadcast$(DlgValue("Broadcast") + 1) & " ß2 rda" End If OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "347 " & MaterialSpec$(DlgValue("MaterialSpec")) & "video file ßb Blu-ray" If DlgValue("BluRayRegions") > 0 Then If BluRayRegions$(DlgValue("BluRayRegions") + 1) <> "all" Then TmpOutput$ = TmpOutput$ & " ße region " & BluRayRegions$(DlgValue("BluRayRegions") + 1) Else TmpOutput$ = TmpOutput$ & " ße " & BluRayRegions$(DlgValue("BluRayRegions") + 1) & " regions" End If End If OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 DlgValue "BluRayRegions", 0 Case 2 'CD MaterialSpec$(1) = Chr(223) & "3 CD: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 3) Else ReDim Preserve OutputList$(3) End If TmpOutput$ = "340 " & Left(MaterialSpec$(DlgValue("MaterialSpec")), 7) & "ßb 4 3/4 in. ß2 rda" OutputList$(UBound(OutputList$) - 2) = TmpOutput$ TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "digital ßb optical" If DlgValue("CDSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & CDSoundChannels$(DlgValue("CDSoundChannels") + 1) End If If DlgText("CDSpecialChar") <> "" Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "h " & DlgText("CDSpecialChar") End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "347 " & MaterialSpec$(DlgValue("MaterialSpec")) & "audio file ßb CD audio" OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "CDSoundChannels", 0 DlgText "CDSpecialChar", "" Case 3 'DVD MaterialSpec$(1) = Chr(223) & "3 DVD: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 3) Else ReDim Preserve OutputList$(3) End If TmpOutput$ = "340 " & Left(MaterialSpec$(DlgValue("MaterialSpec")), 8) & "ßb 4 3/4 in. ß2 rda" OutputList$(UBound(OutputList$) - 2) = TmpOutput$ TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "digital ßb optical" If DlgValue("VideoSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & VideoSoundChannels$(DlgValue("VideoSoundChannels") + 1) End If If DlgText("VideoSpecialChar") <> "" Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "h " & DlgText("VideoSpecialChar") End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ If DlgValue("Broadcast") > 0 Then ReDim Preserve OutputList$(UBound(OutputList$) + 1) TmpOutput$ = "346 " & Left(MaterialSpec$(DlgValue("MaterialSpec")), 8) & "ßb " & Broadcast$(DlgValue("Broadcast") + 1) & " ß2 rda" End If OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "347 " & MaterialSpec$(DlgValue("MaterialSpec")) & "video file ßb DVD video" If DlgValue("DVDRegions") > 0 Then If DVDRegions$(DlgValue("DVDRegions") + 1) <> "all" Then TmpOutput$ = TmpOutput$ & " ße region " & DVDRegions$(DlgValue("DVDRegions") + 1) Else TmpOutput$ = TmpOutput$ & " ße " & DVDRegions$(DlgValue("DVDRegions") + 1) & " regions" End If End If OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 DlgValue "DVDRegions", 0 Case 4 'Large/Giant Print MaterialSpec$(1) = Chr(223) & "3 Book: " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 1) Else ReDim Preserve OutputList$(1) End If TmpOutput$ = "340 " & MaterialSpec$(DlgValue("MaterialSpec")) & "ßn " If DlgValue("TypeSize") = 1 Then TmpOutput$ = TmpOutput$ & "giant print" Else TmpOutput$ = TmpOutput$ & "large print" End If If DlgValue("PointSize") > 0 Then TmpOutput$ = TmpOutput$ & " (" & PointSizeList$(DlgValue("PointSize") + 1) & " point)" End If OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "TypeSize", 0 DlgText "PointSize", "" Case 5 'Playaway MaterialSpec$(1) = Chr(223) & "3 Playaway: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 2) Else ReDim Preserve OutputList$(2) End If TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "digital ßb non-volatile flash memory" If DlgValue("CDSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & CDSoundChannels$(DlgValue("CDSoundChannels") + 1) End If If DlgText("CDSpecialChar") <> "" Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "h " & DlgText("CDSpecialChar") End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "347 " & MaterialSpec$(DlgValue("MaterialSpec")) & "audio file ßb ACELP" OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "CDSoundChannels", 0 DlgText "CDSpecialChar", "" Case 6 'Playaway View MaterialSpec$(1) = Chr(223) & "3 Playaway View: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 2) Else ReDim Preserve OutputList$(2) End If TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "digital ßb non-volatile flash memory" TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "347 " & MaterialSpec$(DlgValue("MaterialSpec")) & "video file ßb Playaway video" OutputList$(UBound(OutputList$)) = TmpOutput$ Case 7 'Record MaterialSpec$(1) = Chr(223) & "3 Record: ßa " 'RPM 'RecordSoundChannels 'Groove 'Diameter If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 2) Else ReDim Preserve OutputList$(2) End If TmpOutput$ = "340 " & MaterialSpec$(DlgValue("MaterialSpec")) & "vinyl" If DiameterList$(DlgValue("Diameter") + 1) <> "Other" Then TmpOutput$ = TmpOutput$ & " ßb " & DiameterList$(DlgValue("Diameter") + 1) End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "analog" TmpOutput$ = TmpOutput$ & " ßc " & RPMList$(DlgValue("RPM") + 1) & " rpm" If DlgValue("Groove") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "d " & GrooveList$(DlgValue("Groove") + 1) place = InStr(TmpOutput$, "(") TmpOutput$ = RTrim(Left(TmpOutput$, place - 1)) End If If DlgValue("RecordSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & CDSoundChannels$(DlgValue("RecordSoundChannels") + 1) End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "RPM", 0 DlgValue "Groove", 0 DlgValue "RecordSoundChannels", 0 DlgValue "Diameter", 0 Case 8 'VHS MaterialSpec$(1) = Chr(223) & "3 VHS cassette: ßa " If OutputList$(1) <> "" Then ReDim Preserve OutputList$(UBound(OutputList$) + 2) Else ReDim Preserve OutputList$(2) End If TmpOutput$ = "344 " & MaterialSpec$(DlgValue("MaterialSpec")) & "analog ßb magnetic" If DlgValue("VideoSoundChannels") > 0 Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "g " & VideoSoundChannels$(DlgValue("VideoSoundChannels") + 1) End If If DlgText("VideoSpecialChar") <> "" Then TmpOutput$ = TmpOutput$ & " " & Chr(223) & "h " & DlgText("VideoSpecialChar") End If TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$) - 1) = TmpOutput$ TmpOutput$ = "346 " & MaterialSpec$(DlgValue("MaterialSpec")) & "VHS" If DlgValue("Broadcast") > 0 Then TmpOutput$ = TmpOutput$ & " ßb " & Broadcast$(DlgValue("Broadcast") + 1) End IF TmpOutput$ = TmpOutput$ & " ß2 rda" OutputList$(UBound(OutputList$)) = TmpOutput$ DlgValue "VideoSoundChannels", 0 DlgText "VideoSpecialChar", "" DlgValue "Broadcast", 0 End Select If TmpOutput$ <> "" Then DlgListBoxArray "SampleOutput", OutputList$ End If If UBound(OutputList$) > 11 Then 'List is longer than one screen; need to find a scrolling workaround to show most recent lines rather than jump back to top of list End If Case "RemoveFromList" DlgFunc34XEntry = TRUE If DlgValue("SampleOutput") > -1 Then OutputList$(DlgValue("SampleOutput") + 1) = "" m = DlgValue("SampleOutput") + 1 n = DlgValue("SampleOutput") Do While m < UBound(OutputList$) OutputList$(m) = OutputList$(m + 1) m = m + 1 Loop If UBound(OutputList$) > 1 Then ReDim Preserve OutputList$(1 To UBound(OutputList$) - 1) Else ReDim Preserve OutputList$(1 To 1) End If DlgListBoxArray "SampleOutput", OutputList$ If n < UBound(OutputList) Then DlgValue "SampleOutput", n ElseIf n > 0 Then DlgValue "SampleOutput", n - 1 End If End If Case "ClearList" DlgFunc34XEntry = TRUE ReDim OutputList$(1 to 1) DlgListBoxArray "SampleOutput", OutputList$ End Select Case 3 ' what to do if text box was changed (by clicking it or by typing in it) Select Case WhichControl$ End Select Case 4 ' what to do if control focus was changed (by leaving it and clicking elsewhere) Case 5 ' what to do while idle (repeated many times/sec) ' ' if some action is supposed to occur while the function is idle, ' then the following line must be used here: ' DlgFuncEditsEntry = TRUE ' succeeded by source code for the action to perform ' (typical examples: timer, checking for user keystrokes, etc.) End Select End Function