<?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>VBA/API</title><link>http://forums.blackbaud.com/forums/20.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP2 (Debug Build: 20611.960)</generator><item><title>API using Visual Studio 2005</title><link>http://forums.blackbaud.com/forums/thread/32569.aspx</link><pubDate>Thu, 07 Aug 2008 00:45:47 GMT</pubDate><guid isPermaLink="false">f90a95a0-00e2-4810-8af8-0bbdde08f853:32569</guid><dc:creator>Peter Falconer</dc:creator><slash:comments>0</slash:comments><comments>http://forums.blackbaud.com/forums/thread/32569.aspx</comments><wfw:commentRss>http://forums.blackbaud.com/forums/commentrss.aspx?SectionID=20&amp;PostID=32569</wfw:commentRss><description>&lt;p&gt;I am writing an app in Vb using Visual Studio 2005 and the RE API and have run into a problem displaying a Constituent form. Strangely I have been able to display an RE&amp;nbsp;Gift form in exactly the same environment and with nearly identical code. Has anyone come upon similar problems?&lt;/p&gt;
&lt;p&gt;The details are ...&lt;/p&gt;
&lt;p&gt;Code&lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;
&lt;blockquote&gt;Dim&lt;/font&gt;&lt;font size="2"&gt; oSuppForm &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;As&lt;/font&gt;&lt;font size="2"&gt; CConstituentForm, oRec &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;As&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;New&lt;/font&gt;&lt;font size="2"&gt; CRecord&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;Try&lt;/p&gt;&lt;/font&gt;&lt;font size="2"&gt;
&lt;p&gt;oRec.Init(REApplication.SessionContext)&lt;/p&gt;
&lt;p&gt;oRec.Load(iRERecID)&lt;/p&gt;oSuppForm = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;New&lt;/font&gt;&lt;font size="2"&gt; CConstituentForm&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;oSuppForm.Init(REApplication.SessionContext)&lt;/p&gt;
&lt;p&gt;oSuppForm.ConstituentObject = oRec&lt;/p&gt;
&lt;p&gt;&lt;/font&gt;&lt;font size="2"&gt;oSuppForm.ShowForm(&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;True&lt;/font&gt;&lt;font size="2"&gt;, , &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;True&lt;/font&gt;&lt;font size="2"&gt;)&lt;/font&gt;&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;end code&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;Error message displayed is &lt;strong&gt;Attempt to access the method failed&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;The same error occurs when I use ShowFormOkCancel as well.&lt;/p&gt;
&lt;p&gt;Blackbaud technical support had no problems running the code. &lt;/p&gt;
&lt;p&gt;Has anyone experienced anything similar? Hopefully with a solution?&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Peter&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;font size="2"&gt;&amp;nbsp;&lt;/p&gt;&lt;/blockquote&gt;&lt;/font&gt;</description></item></channel></rss>