Sub CheckFields() 'This macro will check and report out which custom fields are used 'It is just an example and checks text 1-10 and a few cost and duration 'fields. To make it show all custom fields copy and paste what you 'want to check and increment the field name (see the check for text1 'and text2 as an example) 'Copyright Jack Dahlgren, feb. 2002 Dim mycheck As Boolean Dim usedfields As String Dim Tcount As Integer Dim ts As Tasks Set ts = ActiveProject.Tasks usedfields = "The following custom fields are being used:" & vbCr 'the following section is how to check text1 mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then 'to use for a different field change text1 to text2 'in the next two lines If ts(Tcount).Text1 <> "" Then usedfields = usedfields & "Text1" & vbCr mycheck = True End If End If Wend 'this section checks text2 - repeat as necessary to 'check all fields mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text2 <> "" Then usedfields = usedfields & "Text2" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text3 <> "" Then usedfields = usedfields & "Text3" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text4 <> "" Then usedfields = usedfields & "Text4" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text5 <> "" Then usedfields = usedfields & "Text5" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text6 <> "" Then usedfields = usedfields & "Text6" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text7 <> "" Then usedfields = usedfields & "Text7" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text8 <> "" Then usedfields = usedfields & "Text8" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text9 <> "" Then usedfields = usedfields & "Text9" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Text10 <> "" Then usedfields = usedfields & "Text10" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Cost1 <> 0 Then usedfields = usedfields & "Cost1" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Cost2 <> 0 Then usedfields = usedfields & "Cost2" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Duration1 > 0 Then usedfields = usedfields & "Duration1" & vbCr mycheck = True End If End If Wend mycheck = False Tcount = 0 While Not mycheck And (Tcount < ts.Count) Tcount = Tcount + 1 If Not ts(Tcount) Is Nothing Then If ts(Tcount).Duration2 > 0 Then usedfields = usedfields & "Duration2" & vbCr mycheck = True End If End If Wend MsgBox prompt:=usedfields, Title:="Custom Fields in Use" End Sub