Showing results for 
Search instead for 
Do you mean 

fully qualified real field name from display name

Copper Super Contributor
Posts: 52
Country: United_Kingdom

fully qualified real field name from display name

Hi everyone,


Here's a quick sample that gets a fully qualified real field name from display name. It comes in useful for most work with fields such as lookup, reading data and setting data.



Dim field As String = getRealField(oApp, "ID/Status", RecordType.Contact)


Return example



I find it useful to use this in highly customized databases where new fields might be going to a spillover table and don't necessarily exist in TBL_CONTACT, TBL_COMPANY ect..


Private Function getRealField(ByVal ActApp As ActApplication, ByVal DisplayName As String, ByVal RecordType As RecordType) As String
        Dim returnValue As String = ""

        Dim fields As FieldDescriptorCollection = ActApp.ActFramework.Fields.GetFields(RecordType)

        For Each field As FieldDescriptor In fields
            If field.Name = DisplayName Then
                returnValue = field.TableName + "." + field.ColumnName
            End If

        Return returnValue
    End Function



private string getRealField(ActApplication ActApp, string DisplayName, RecordType RecordType)
	string returnValue = "";

	FieldDescriptorCollection fields = ActApp.ActFramework.Fields.GetFields(RecordType);

	foreach (FieldDescriptor field in fields) {
		if (field.Name == DisplayName) {
			returnValue = field.TableName + "." + field.ColumnName;

	return returnValue;

 I hope this helps someone.







Copper Super Contributor
Posts: 485
Country: Australia

Re: fully qualified real field name from display name

Thanks Russell

Jason Dawson Financial Planning
Brisbane | Australia - JDFP Home Page

Act Ver - Act! Premium Version, Hot Fix 3
OS - Windows 7 (stand alone machine)
MS Office - Enterprise 2007
Phone - Samsung Galaxy s6