One aspect of the API that is really well thought out is the whole Meta data structure. Back when RE7 was written, there was no reflection built into VB6. Java had it and there was some libraries that could do it but nothing was built in. Reflection (in coding terminology) is the ability to be aware of the classes and methods that are available to the code during run time.
Tag Archives: Constituent
Most Visited Plugins for February
Here are the top 10 visited plugins for the month of February. These are ordered by plugins whose follow through link as been visited.
1 Convio DataSync Connector RE
2 Create Preferred Address
3 Action Reminder Updater
4 Alternate Address Deleter
5 Bank Checker Solution
6 Clean Static Queries
7 AFP
8 Audit Trail
9 Add Constituent ID
10 Custom Reports
Newly added plugins
Thank you Steve Best for the following five new entries to the plugin directory. If there are any more that have been missed any then feel free to add them. Thank you to all those who have added over the past months.
Cannot find the plugin that you are looking for? Get in contact with us and find out how we can make your Raiser’s Edge processes more efficient and make savings in both time and money.
Describe a constituent in their dialogue window
When you open up a constituent record wouldn’t it be good to see a one line overview of the most important distinguishing features of their record even if they are on different tabs? This tip shows you how to put this information into the window dialogue title.
Continue reading Describe a constituent in their dialogue window
Membership – Retrieving information
One very useful way of loading a collection of records is using the custom where clause. For example if you want to find a list of constituents who are born in a certain year you could write the following
Dim oRecords As New CRecords
oRecords.INIT SessionContext, tvf_record_CustomWhereClause, "BIRTH_DATE LIKE '1950%'"
This is the only really effective way of doing this without returning a list of all constituents filtering them in the code (much less efficient).
Filtering and Sorting Participants – Just not Together
This is being written in response to two hours of trying to get some code to work only to conclude that there was a bug in the API. I am not overly convinced it will be documented any time soon so let it be documented here!
I wanted to create a collection of participant registrations for a particular constituent. I also wanted to only really look at the most recent three registrations so I needed to both filter and sort. Sounds quite simple really until of course it did not work.
Continue reading Filtering and Sorting Participants – Just not Together
Excel Revisited
In a previous post (Integrating with Excel) I gave a code example of how RE can integrate with Excel. The code was relatively simple. One of the problems with working with Excel is if you embed references to Excel in your project but you are not sure of the version of Excel you will be working with.
Fund Missing (Found in an Unexpected Place)
I had an error that bugged me for a while when I could not work out what the problem was.
I had a list of gifts that I wanted to create on different constituents. I had the constituent id, the date, amount, fund, appeal, campaign, everything that I thought was required.
I got the following error message when trying to save the newly created gift:
Required Field Missing: Fund
Continue reading Fund Missing (Found in an Unexpected Place)
Top Plugins in November
Here are the most popular plugins for the month of November from the plugin directory. This is based on the click through for more information link.
- Audit Trail
- Action Reminder Updater
- Convio DataSync Connector RE
- Blackbaud NetCommunity Integration
- Constituent Document Linker
- Bank Checker Solution
- Create Preferred Address
- Alternate Address Deleter
- AFP
- Custom Reports
Cannot find the plugin that you are looking for? Get in contact with us and find out how we can make your Raiser’s Edge processes more efficient and make savings in both time and money.
Integrating with Excel
Two common tasks seem to be integrating RE with an Excel file. This can mean two things. Either from a plugin or some RE:VBA code opening a Excel file and extracting the data or it can mean that from within Excel VBA access the RE objects to retrieve some data. The way you handle the two scenarios is quite different.
If you are trying to connect to Raiser’s Edge from Excel you will need the API module. You connect to RE using the REAPI object and initialize it with a serial number and optionally user name and password. You then use the API in exactly the same way as you would from within RE, i.e. via VBA or any other API application.
If you want to open up Excel from RE then you will need to create the application objects. This is shown in the example below:
Dim objExcel As Excel.Application ' Excel application Dim objBook As Excel.Workbook ' Excel workbook Dim objSheet As Excel.Worksheet ' Excel Worksheet Dim oConstit As New CRecord oConstit.Init REApplication.SessionContext Set objExcel = CreateObject("excel.application") 'Starts the Excel Session Set objBook = objExcel.Workbooks.Open("C:test.xls") For Each objSheet In objBook.Sheets If UCase(objSheet.Name) = "Sheet1" Then oConstit.Load CLng(objSheet.Range("A2").Text) objSheet.Range("A3").Text = oConstit.Fields(RECORDS_fld_FULL_NAME) Exit For End If Next objSheet objBook.Save If Not objBook Is Nothing Then objBook.Close Set objBook = Nothing End If If Not objExcel Is Nothing Then objExcel.Quit Set objExcel = Nothing End If
This is quite self-explanatory code, although Excel has an object model just as RE does which is very large and takes a while to get to understand. There is plenty of Excel API information on MSDN.