<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.blackbaud.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Search results matching tag 'VBA'</title><link>http://forums.blackbaud.com/search/SearchResults.aspx?o=DateDescending&amp;tag=VBA&amp;orTags=0</link><description>Search results matching tag 'VBA'</description><dc:language>en-US</dc:language><generator>CommunityServer 2007 SP2 (Debug Build: 20611.960)</generator><item><title>Use of REApplication object in VBA</title><link>http://forums.blackbaud.com/forums/p/10591/38220.aspx#38220</link><pubDate>Mon, 24 Nov 2008 18:37:59 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:38220</guid><dc:creator>47EBEBFF-1807-42F0-9B47-861F51022039</dc:creator><description>&lt;p&gt;Hi ... Has anyone tried to use the REApplication object and specifically writing code for the UIOpening and UIClosing events ? The vba documentation (admittedly limitted) suggests that VB code can be written to execute code when the user starts up a Raisers Edge session. I would like to take advantage of this, but do not have any examples for the event subroutine calls.&lt;/p&gt;
&lt;p&gt;Thx Nigel&lt;/p&gt;</description></item><item><title>Search for Constituents by bank account</title><link>http://forums.blackbaud.com/forums/p/10329/37567.aspx#37567</link><pubDate>Sun, 19 Oct 2008 16:58:38 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:37567</guid><dc:creator>51CA828C-2740-4A43-8ABA-E04CEF1FE4D2</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I&amp;#39;m looking for a way to find contstituents by their bank account.&lt;/p&gt;
&lt;p&gt;As off version 7.81 the account numbers are encrypted in the DB. &lt;br /&gt;Using the standard CustomWhereClause doesn&amp;#39;t work because it queries the raw (encrypted) data.&lt;/p&gt;
&lt;p&gt;Is there a way to encrypt the plain text (account no) and pass that in the customwhereclause ?&lt;br /&gt;Or another filter object&amp;nbsp;where I can give the account no in plain text as a parameter that returns a constituent collection ?&lt;/p&gt;
&lt;p&gt;Eric&lt;/p&gt;</description></item><item><title>VBA Event on Batch new line</title><link>http://forums.blackbaud.com/forums/p/9904/33347.aspx#33347</link><pubDate>Fri, 29 Aug 2008 01:30:20 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:33347</guid><dc:creator>02e4d6ac-3dca-4c0c-b23e-72bd93449eaa</dc:creator><description>&lt;p&gt;&amp;nbsp;We&amp;#39;re wanting to run a duplicate check on each line of a constituent batch, as the data is being entered, so that at the end of the batch we know that everyone of the records has been checked.&lt;/p&gt;&lt;p&gt;Currently, we have in the user procedure to click on each line, then do a &amp;quot;Duplicate Search For xxxxxx&amp;quot; in the menus, but users being users, this isn&amp;#39;t always done to an acceptable standard. So we want to force them to do this, every line.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;I have tested out all of the VBA events to see when they are triggered, and these ones I don&amp;#39;t think ever fired in my testing:&lt;br /&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; Batch_BeforeBarCodeLookup&lt;br /&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; Batch_BeforeValidateRecord2&lt;br /&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; Batch_BatchException&lt;br /&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; Batch_AfterPostRecord&lt;br /&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; BatchVBARecord_HandleException&lt;br /&gt;Certainly none fired as each line was being entered....&lt;/p&gt;&lt;p&gt;&amp;nbsp;Does anyone know of an event that we can capture, or a way to automatically run the duplicate check on each line during entry instead of on the entire batch?&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Queue; multiple queries to be refreshed</title><link>http://forums.blackbaud.com/forums/p/9587/32335.aspx#32335</link><pubDate>Tue, 29 Jul 2008 19:12:44 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:32335</guid><dc:creator>AEBCDA46-BA74-4CEC-A05F-C880E09397C3</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;I&amp;#39;d love your thoughts on how to approach the following issue:&lt;/p&gt;
&lt;p&gt;I have a monthly process that entails refreshing 15-20 queries with a specific date range (i.e. June 20-July 21) and then doing 5-6 exports based off of various of the queries.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Currently, the process takes 4-6 hours due to the size and complexity of the queries and exports.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;We have RE:QUEUE.&amp;nbsp; However, it cannot auto-advance the dates to the next month.&amp;nbsp; Thus I must either be there to refresh the dates using an ask operator, or I must manually perform the process.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;Any thoughts at all would be appreciated, including customization suggestions using VBA or API or another appropriate methodology.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Many thanks!&lt;/p&gt;
&lt;p&gt;Faith&lt;/p&gt;</description></item><item><title>UserForm not on Windows taskbar</title><link>http://forums.blackbaud.com/forums/p/9332/31712.aspx#31712</link><pubDate>Mon, 30 Jun 2008 14:59:03 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:31712</guid><dc:creator>60E2D44C-288D-4386-94F5-17635FE1D8A5</dc:creator><description>&lt;p&gt;I&amp;#39;m new to RE VBA and appreciate any assistance with the following problem :)&lt;/p&gt;
&lt;p&gt;When I launch a VBA userform through a macro from the RE shell it does not appear on the Windows taskbar. So if I switch to another application (like Excel) I can&amp;#39;t get back to the userform by clicking an icon on the taskbar or using ALT-Tab to rotate through windows. RE itself disappears from the Alt-Tab. There is still an RE icon on the taskbar but when I click it I go back to the RE and not to the userform. Since the userform is still open I hear the &amp;quot;thunk&amp;quot; that tells me a window is open and needs to be closed...since I can&amp;#39;t access it I can&amp;#39;t close it so effectively RE has crashed.&lt;/p&gt;
&lt;p&gt;I get the same behavior whether the &amp;quot;ShowModal&amp;quot; property of the form is set to &amp;quot;true&amp;quot; or false.&lt;/p&gt;
&lt;p&gt;Thanks in advance for any suggestions on correcting this!&lt;/p&gt;
&lt;p&gt;Thanks,&lt;br /&gt;Frank&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Calendar Control</title><link>http://forums.blackbaud.com/forums/p/9195/31388.aspx#31388</link><pubDate>Thu, 12 Jun 2008 23:26:50 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:31388</guid><dc:creator>EA510BD0-8193-4A50-9EAC-58C4C883D722</dc:creator><description>&lt;p&gt;I am looking for a calendar (date) control like the one that appears in the date column of the attributes pages in RE.&lt;/p&gt;&lt;p&gt;It is not one of the default controls. I tried RE7_SC72.SuperCalendar, but that is not what I want.&lt;br /&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Forms</title><link>http://forums.blackbaud.com/forums/p/9187/31360.aspx#31360</link><pubDate>Wed, 11 Jun 2008 23:45:49 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:31360</guid><dc:creator>EA510BD0-8193-4A50-9EAC-58C4C883D722</dc:creator><description>&lt;p&gt;I am creating a macro for entering a new individual consitutent. Unfortunately the only reference I have found so far to Forms in the RE VBA esentials guide is on page 98, where it indicates that &amp;quot;VBA provides full-featured forms design support&amp;quot;, where I &amp;quot;can design a custom data entry form&amp;quot;. It does not however, explain how to do this. After much reseach, trial, and error I have found that I must start the macro with the following code in the module named &amp;quot;User_Macros&amp;quot;:&lt;/p&gt;&lt;p&gt;Public Sub AddNewMember()&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Load frmNewMembers&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; frmNewMembers.Show&lt;br /&gt;&lt;br /&gt;End Sub&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Where &amp;quot;AddNewMember&amp;quot; is the name of the macro. Now my macro is being terminated as follows:&lt;/p&gt;&lt;p&gt;Private Sub cmdExit_Click()&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; moCodeTablesServer.Closedown&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set moCodeTablesServer = Nothing&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; End&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;End Sub&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;This is taking place in the form, not in the original User_Macro module. The &amp;quot;Closedown&amp;quot; and &amp;quot;Nothing&amp;quot; lines are to shut down the Code Tables Server that I am using to load a combo box -- it took me quite awhile to figure out how to do this also, especially since there was an error in the sample code. But I am wondering if I am going to end up with any memory leaks from not unloading the form? Is this done automatically as part of the &amp;quot;End&amp;quot; statement? I cannot figure out how to return to the original code and unload the form.&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Creating an Action on Save</title><link>http://forums.blackbaud.com/forums/p/8848/30661.aspx#30661</link><pubDate>Fri, 09 May 2008 02:05:20 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:30661</guid><dc:creator>88105A16-FFA2-43EC-A7BE-D01D62236774</dc:creator><description>&lt;p&gt;You would need the VBA module [edit: as David&amp;nbsp;mentioned]&amp;nbsp;rather than an API&amp;nbsp;license to do this. This code shows&amp;nbsp;one way to track what&amp;nbsp;values were changed TO, but you could extend it further&amp;nbsp;to also track/log initial values.&amp;nbsp;I don&amp;#39;t know that actions are good place to store audit trail though, as a user could change the action records (and you&amp;#39;ll have a LOT of action records). I would recomend a separate database table.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Public Sub Constituent_BeforeSave(oRecord As Object, bCancel As Boolean)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim oM As IBBMetaField, oD As IBBDataObject&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oD = oRecord&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oM = oRecord&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim sChaChaChaChanges As String&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim i As Long&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; For i = 1 To oM.Count&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If oD.FieldIsDirty(i) Then&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sChaChaChaChanges = sChaChaChaChanges &amp;amp; oM.DisplayText(i) &amp;amp; &amp;quot; changed to &amp;#39;&amp;quot; &amp;amp; oD.Fields(i) &amp;amp; &amp;quot;&amp;#39;&amp;quot; &amp;amp; vbCrLf&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End If&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next i&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim oConstit As CRecord&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If Len(sChaChaChaChanges) Then&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim oA As CAction, oA2 As IBBAction2&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oA = New CAction&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; oA.Init REApplication.SessionContext&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; oA.Fields(ACTION_fld_RECORDS_ID) = oD.Fields(RECORDS_fld_ID)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; oA.Fields(ACTION_fld_CATEGORY) = &amp;quot;Task/Other&amp;quot;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oA2 = oA&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; With oA2.Notepads.Add&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .Fields(NOTEPAD_fld_NotepadDate) = FormatDateTime(Now, vbShortDate)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .Fields(NOTEPAD_fld_NotepadType) = &amp;quot;Audit Trail&amp;quot; &amp;#39;&amp;lt;-- use a valid type&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .Fields(NOTEPAD_fld_Description) = &amp;quot;changes at &amp;quot; &amp;amp; Now&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .Fields(NOTEPAD_fld_Notes) = sChaChaChaChanges&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End With&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; oA.Save&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; oA.Closedown&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oA = Nothing&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oA2 = Nothing&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; End If&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set oD = Nothing&lt;/p&gt;
&lt;p&gt;End Sub&lt;/p&gt;</description></item><item><title>Re: Creating an Action on Save</title><link>http://forums.blackbaud.com/forums/p/8848/30615.aspx#30615</link><pubDate>Wed, 07 May 2008 16:09:53 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:30615</guid><dc:creator>82205EDC-D36A-44E9-97CA-C3CEAE5AAF7D</dc:creator><description>&lt;p&gt;Absolutely. This is a straight forward task. Using the VBA module you would capture the values before the record is opened and then on saving the record you would compare the values to those when the record was opened and record any change. This is common where you want to keep an audit trail of changes made.&lt;/p&gt;
&lt;p&gt;Please don&amp;#39;t hesistate to contact me if you would like any more information.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;David&lt;/p&gt;</description></item><item><title>Log To SQL</title><link>http://forums.blackbaud.com/forums/p/8351/29500.aspx#29500</link><pubDate>Mon, 10 Mar 2008 21:39:43 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:29500</guid><dc:creator>76BA76AC-5DB3-4D0D-ABDB-71753008B104</dc:creator><description>&lt;p&gt;We&amp;#39;ve got a VBA macro and would like to log when whenever someone runs it and the context (what record were they in at the time). So basically, I want to capture the Date, Time, UserName, and ConstituentID-UserName of the record they were in at the time. Ideally, I&amp;#39;d like to send this information to a SQL table in a database on the same server as RE, but not the RE database. I have some code I&amp;#39;ve created for pulling information out of SQL and pulling it into RE and I was going to use that. However, I realized that it depends on having a DSN pointing to the other database and I don&amp;#39;t want to do that for all of my users.&lt;/p&gt;&lt;p&gt;I&amp;#39;m very handy with SQL - much less so in VBA.&lt;/p&gt;&lt;p&gt;Does anyone have anything that might fit the bill?&lt;/p&gt;&lt;p&gt;Thanks!&lt;/p&gt;&lt;p&gt;Mitch&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>