﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » WebForms (How do I?)  » Missing Global.asax?</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Mon, 08 Jun 2026 22:32:02 GMT</lastBuildDate><ttl>20</ttl><item><title>Missing Global.asax?</title><link>http://forum.strataframe.net/FindPost16294.aspx</link><description>I'm getting an error about the DataSourceKey is not defined...&lt;/P&gt;&lt;P&gt;I did some checking on here and in the sample app and found that there is a global.asax in the sample app that I don't have in my app.&amp;nbsp; Additionally, looks like that's where I am supposed to setup the data connection.&lt;/P&gt;&lt;P&gt;So, here are my questions...&lt;/P&gt;&lt;P&gt;Do I need a global.asax and&amp;nbsp;what is it for?&amp;nbsp; &lt;/P&gt;&lt;P&gt;If it is necessary,&amp;nbsp;should it have been added when I created the project?&amp;nbsp; &lt;/P&gt;&lt;P&gt;Lastly, if I add one, will that take care of my DataSourceKey error?&lt;/P&gt;&lt;P&gt;Thanks again for any help!&lt;/P&gt;&lt;P&gt;HB</description><pubDate>Fri, 09 May 2008 10:41:02 GMT</pubDate><dc:creator>Howard Bennett</dc:creator></item><item><title>RE: Missing Global.asax?</title><link>http://forum.strataframe.net/FindPost16296.aspx</link><description>I was using 1.6.5 - but - downloaded it again (must have been an update I missed.)&amp;nbsp; Now, the global.asax is there.&lt;/P&gt;&lt;P&gt;Thanks - on to the next issue.&lt;/P&gt;&lt;P&gt;HB</description><pubDate>Fri, 09 May 2008 10:41:02 GMT</pubDate><dc:creator>Howard Bennett</dc:creator></item><item><title>RE: Missing Global.asax?</title><link>http://forum.strataframe.net/FindPost16295.aspx</link><description>[quote]Do I need a global.asax and&amp;nbsp;what is it for?&amp;nbsp; [/quote]&lt;/P&gt;&lt;P&gt;Unless you plan to have nothing but static pages, then yes.&amp;nbsp; You will need a global.asax.&amp;nbsp; This file is launched when the application starts up in IS as well as when a new session is started.&amp;nbsp; There are associated events that can be handled in this class as well.&amp;nbsp; So when you application starts, you will want to define your connection string information there..this way it is only created once versus for each session (each visitor)&amp;nbsp;that gets started.&lt;/P&gt;&lt;P&gt;[quote]If it is necessary,&amp;nbsp;should it have been added when I created the project?&amp;nbsp; [/quote]&lt;/P&gt;&lt;P&gt;There was a bug in the template until 1.6.5 that did not include the global.asax file...this has been fixed.&lt;/P&gt;&lt;P&gt;[quote]Lastly, if I add one, will that take care of my DataSourceKey error?[/quote]&lt;/P&gt;&lt;P&gt;Yes...you have to define your connection and this is the only place that you should really do this on a web application.</description><pubDate>Fri, 09 May 2008 10:13:15 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item></channel></rss>