How to write code to return applicant ethnicity in BBSIS version 7.80 and above

This article demonstrates how to write a macro that will return an applicant's ethnicity from BBSIS version 7.80 and above.

Public Sub EAApplicant_AfterSave(oRecord As Object)
    'oRecord              : record object saved
    Dim oApp As cEAApplicant
    Set oApp = oRecord
    Dim lID As Long
    lID = oApp.Fields(EAAPPLICANTS_fld_EA7APPLICANTSID)
    'This displays the original value
    Debug.Print oApp.Fields(EAAPPLICANTS_fld_ETHNICITY)
    EthnicityTest2 lID
   
    Set oApp = Nothing
End Sub

Public Sub EthnicityTest2(lID As Long)
    Dim oApplicant As cEAApplicant
    Set oApplicant = New cEAApplicant
    oApplicant.Init FE_Application.SessionContext
    oApplicant.Load lID, True
   
    'This displays the new value
    Debug.Print oApplicant.Fields(EAAPPLICANTS_fld_ETHNICITY)
   
    oApplicant.CloseDown
    Set oApplicant = Nothing
End Sub

Blackbaud provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with Microsoft Visual Basic and the tools used to create and debug procedures.  Blackbaud Customer Support can help explain the functionality of a particular procedure but they will not modify, or assist you with modifying, these examples to provide additional functionality.  If you are interested in learning more about VBA and API modules, contact our Sales department at solutions@blackbaud.com.
 

Environment

 7.80.94

Was this article helpful?


Thanks for your feedback! Did this solve your issue?

Comments (optional):


Thanks for your feedback!
We're glad it was helpful but sorry it didn’t solve your issue. If you need assistance, click Chat with Support below.
We’re sorry to hear that. Please tell us why.

 I don't like how this works.

 The answer is confusing.

 The answer didn't match what I was searching for.

Additional Comments (optional):


Thanks for your feedback! If you need assistance, click Chat with Support below.
Thanks for your feedback. Help us make our products even better by sharing details in our Idea Banks or our online Community.
Thanks for letting us know. We'll work on clarifying the information in the article. If you need assistance, click Chat with Support below.
Thanks for letting us know. We'll work on updating the search engine to return more relevant results.