<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-3826499523933116283</id><updated>2012-02-16T05:54:16.521-08:00</updated><category term='new wiki site'/><category term='new subsite'/><category term='sharepoint'/><category term='team site'/><category term='sub site'/><category term='recerate'/><category term='File not found'/><category term='OracleXEListener'/><title type='text'>Hoysala</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>9</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-4907912329837561699</id><published>2010-02-09T11:42:00.000-08:00</published><updated>2010-02-09T11:42:38.741-08:00</updated><title type='text'>Grid CausedCallback and IsCallback values are incorrect</title><content type='html'>I am using a ComponentArt grid on one of the ASP.Net pages. In the Page_Load() I have the code to load the grid. The code looks something like this...&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;protected void Page_Load(object sender, System.EventArgs e)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;if(Page.IsPostBack == false)&lt;br /&gt;&amp;nbsp;&amp;nbsp;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;buildGrid();&lt;br /&gt;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;This works well, the buildGrid() is called only when the page is loaded for the first time and when a postback occurs the function is skiiped.&lt;br /&gt;&lt;br /&gt;However my grid a paging enabled and grid runs at server side (runat="server"). This mean grid would postback everytime you naviage from page to page. So adding another check as follows...&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;protected void Page_Load(object sender, System.EventArgs e)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;if(Page.IsPostBack == false &amp;amp;&amp;amp;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;Grid1.CausedCallabck ==false )&lt;br /&gt;&amp;nbsp;&amp;nbsp;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;buildGrid();&lt;br /&gt;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This means buildGrid() is skipped when when Grid1 caused the callback (e.g. navigating from page to page within the grid).&lt;br /&gt;&lt;br /&gt;But here is the problem. The Grid1.CausedCallback is false when you load the page for the first time and changes to true when you change pages on the grid but remain true there after. Even if you navigate away from the page that contains the grid to something totally different and come back to this page Grid1.CausedCallback remains true. This can cause many problem based on the implementation you have.&lt;br /&gt;&lt;br /&gt;I am not sure what the problem is, it could be a bug in the component itself. I did spend sometime to figure it out but with no luck. So I decided to use a work around.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Work around:&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;The Request object has a property called UrlReferrer. This basically tells us from which page the request is coming to the current page. This mean when ever the UrlReferrer is otherthan current page(page with the grid) we know the user is landing on current page for the first time. So the final code looks something like this.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;protected void Page_Load(object sender, System.EventArgs e)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;string url = Request.UrlReferrer.ToString();&lt;br /&gt;&amp;nbsp;&amp;nbsp;if(Page.IsPostBack == false &amp;&amp;     &lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; url.ToLower().Contains("currentpagename.aspx")==false )&lt;br /&gt;&amp;nbsp;&amp;nbsp;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;buildGrid();&lt;br /&gt;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-4907912329837561699?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/4907912329837561699/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=4907912329837561699' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/4907912329837561699'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/4907912329837561699'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2010/02/grid-causedcallback-and-iscallback.html' title='Grid CausedCallback and IsCallback values are incorrect'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-4368865697965122029</id><published>2009-08-31T13:23:00.000-07:00</published><updated>2009-08-31T13:23:31.136-07:00</updated><title type='text'>Unable to connect to internet in Virtual PC</title><content type='html'>I ran into this issue recently. I installed Microsoft Virtual PC on my host machine running Windows XP. Created a new Virtual PC and installed Windows Service Pack3 on it. By default the Networking adapter is set to the physical network adapter of the host machine. Everything looked good so I fired up my new VPC, opened the browser and tried accessing some site. Problem! &lt;br /&gt;&lt;br /&gt;So I decided to change the Network work adapter of the VPC to Shared Netowrking (NAT). In this mode VPC would share the network connection available on the host machine instead connecting directly to the network adapter on the host machine. But still no luck.&lt;br /&gt;&lt;br /&gt;In both cases I could ping the host machine from the Virtual PC. Which meant there is network connection on VPC but something is preventing internet connections. The first thing to look at in such scenario would be Firewall. So I decided to quickly check if disabling the firewall on the VPC would do the trick. That didn't make any difference. Note disabling firewall is not a good idea. I was just using to narrow the issue down. So I turned the firewall back on on the VPC.&lt;br /&gt;&lt;br /&gt;The next step was to look at the Firewall on the host machine. Instead of disabling the firewall this time I looked at the Exception tab of the firewall configuration window. This tab basically lists the applications that have previlages to pass through the firewall. I decided to add Microsoft Virtual PC into the list. After adding it to the list, clicked on the "Add Port" button and added port 80. That's it!!!&amp;nbsp;The problem is fixed.&amp;nbsp;Hope this helps some one. Drop a line if this worked or you have any comments.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-4368865697965122029?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/4368865697965122029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=4368865697965122029' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/4368865697965122029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/4368865697965122029'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2009/08/unable-to-connect-to-internet-in.html' title='Unable to connect to internet in Virtual PC'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-7077262361987918071</id><published>2009-02-04T14:16:00.000-08:00</published><updated>2009-02-04T14:23:30.896-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sharepoint'/><category scheme='http://www.blogger.com/atom/ns#' term='recerate'/><category scheme='http://www.blogger.com/atom/ns#' term='team site'/><category scheme='http://www.blogger.com/atom/ns#' term='sub site'/><title type='text'>File not found when recreating a sub site in SharePoint</title><content type='html'>For whatever reason I had to delete a sub site that I create under the default team site in SharePoint. The deleting is easy. But when you try to recreate the same site again you would get&lt;br /&gt;&lt;br /&gt;File not found followed by a stack trace&lt;br /&gt;&lt;br /&gt;Just restarting the IIS should fix the problem&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-7077262361987918071?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/7077262361987918071/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=7077262361987918071' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7077262361987918071'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7077262361987918071'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2009/02/file-not-found-when-recreating-sub-site.html' title='File not found when recreating a sub site in SharePoint'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-7295894105312296145</id><published>2009-02-03T12:16:00.000-08:00</published><updated>2009-02-03T12:30:33.993-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sharepoint'/><category scheme='http://www.blogger.com/atom/ns#' term='new wiki site'/><category scheme='http://www.blogger.com/atom/ns#' term='new subsite'/><category scheme='http://www.blogger.com/atom/ns#' term='File not found'/><title type='text'>File Not Found when creating a new site in SharePoint</title><content type='html'>I ran into this problem when creating a new sub site (Sites and Workspaces) under the default team site that gets created when you install SharePoint Services. I would get &lt;strong&gt;File Not Found&lt;/strong&gt; every time I tried creating a new site under the main site. Though I found lot of information on the internet on resolving the issue, none of them worked for me.&lt;br /&gt;&lt;br /&gt;The solution is very simple. Under STN Team Site &gt; Site Settings &gt; Sites and Workspaces  click on "Site Creating Permission" button. Select the "Design" permission level and click OK. That's it, now you should be able to create any number of new sites.&lt;br /&gt;&lt;br /&gt;The error &lt;strong&gt;File Not Found&lt;/strong&gt; is miss leading when the issue is related to permissions.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-7295894105312296145?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/7295894105312296145/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=7295894105312296145' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7295894105312296145'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7295894105312296145'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2009/02/file-not-found-when-creating-new-site.html' title='File Not Found when creating a new site in SharePoint'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-8271195098478561161</id><published>2008-07-03T08:00:00.000-07:00</published><updated>2008-07-03T08:23:01.623-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='OracleXEListener'/><title type='text'>OracleXETNSListener colud not be started</title><content type='html'>I have been using Oracle XE for months and suddenly one day I could not connect to the database. I found that the listener was not running and I attempted stop and then start the listener through the menu options(Programs-&gt;Oracle 10g Express Edition-&gt;Start Database,StopDatabase). The listener did not start.&lt;br /&gt;&lt;br /&gt;I found many forums that talked about the same issue. Different solutions worked for different people. I tried all the solutions that were recommended but none of them really fixed my problem. One of the forum recommended reinstalling OracleXE. (Note: reinstalling will wipe out any database that you already have on XE). There are instuction to get around this problem, see Oracle XE Installation instructions for more info. So I decided to reinstall Oracle XE but it is not as straight as one might think. Here are the steps that I followed&lt;br /&gt;&lt;br /&gt;1. login to the machine as administrator (this seems to be very important). You may be thinking your domain account as local administrator rights. That doesn't really matter. Oracle requires you to login as adminstrator of the machine.&lt;br /&gt;&lt;br /&gt;2. Run Oracle XE setup exe. You will be prompted to either Repair or Remove. Choose Remove.&lt;br /&gt;&lt;br /&gt;3. Complete the remove process.&lt;br /&gt;&lt;br /&gt;4. Open Environment variables (My Computer-&gt;Properties-&gt;Advanced-&gt;Environment Variables)&lt;br /&gt;&lt;br /&gt;5. Remove ORACLE_HOME and ORACLE_SID system variables (This is very important. My previous attempt without this step did not fix my problem)&lt;br /&gt;&lt;br /&gt;6. Reboot the machine. (one more important step)&lt;br /&gt;&lt;br /&gt;7. Log in as administrator&lt;br /&gt;&lt;br /&gt;8. Install Oracle XE&lt;br /&gt;&lt;br /&gt;That's it! You should be able to open Oracle Home.&lt;br /&gt;&lt;br /&gt;Drop couple of lines if this worked for you.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-8271195098478561161?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/8271195098478561161/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=8271195098478561161' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/8271195098478561161'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/8271195098478561161'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2008/07/oraclxetnslistener-colud-not-be-started.html' title='OracleXETNSListener colud not be started'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-7600886601614946286</id><published>2008-06-05T07:53:00.000-07:00</published><updated>2008-06-05T08:10:58.073-07:00</updated><title type='text'>Cannot open Oracle XE database home page</title><content type='html'>Sometimes when you install Oracle XE on your desktop and try to access the home page through the internet explorer, it may not open and IE displays an error page. There are two things that seem to fix the problem&lt;br /&gt;&lt;br /&gt;1. When you install Oracle XE on your desktop, login as local administrator instead of your company domain account. The install instruction says as long your domain account has administration rights on the computer it will work. But that's not the case when I installed XE. So I uninstalled oracle xe, logged off as domain user, logged back-in as local adminstrator.&lt;br /&gt;&lt;br /&gt;The username for local administrator is usually "administrator." If you don't remember the password, you can just reset it by logging in as domain user.&lt;br /&gt;&lt;br /&gt;If you are trying to open the database home from a different machine than the machine running Oracle XE, you may want to do the following&lt;br /&gt;&lt;br /&gt;1. Make sure remote connection is allowed to this database. For that you will have to goto the machine where the database is running and change the setting. The option is available under administrative task.&lt;br /&gt;&lt;br /&gt;2. Also make sure the firewall is not enable on machine where the database is running. If the firewall is enabled, it may block the calls to communicate with the database. Chaning the fire wall settings is very easy. Select the LAN connection properties. Click advanced tab and then click settings. Here you can enable\disable firewall.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-7600886601614946286?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/7600886601614946286/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=7600886601614946286' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7600886601614946286'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/7600886601614946286'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2008/06/cannot-open-oracle-xe-database-home.html' title='Cannot open Oracle XE database home page'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-8767770642279173564</id><published>2007-11-01T13:50:00.001-07:00</published><updated>2007-11-01T14:29:51.714-07:00</updated><title type='text'>Automation Error System cannot find the file specified</title><content type='html'>You might run it to this problem when you are trying to load a COM exposed .net component from a COM application such as VB. The problem is that the COM is not able to find your component in the registry. Here are some of the resolutions you can try&lt;br /&gt;&lt;br /&gt;- Enable Register for COM interop in the project properties window&lt;br /&gt;&lt;br /&gt;This use to be enough in .Net 1.1 /VS 2003 to get the component registered. But in .Net 2.0/VS 2005, Microsoft introduced another way to specify the COM visibility. That is by introducing a new attribute [assembly: ComVisible(true)]. Add this attribute to your AssemblyInfo.cs file and recompile the project.&lt;br /&gt;&lt;br /&gt;If you are still having the problem, try registering the component explicitly using&lt;br /&gt;&lt;br /&gt;regasm c:\abc\abc.dll /tlb&lt;br /&gt;&lt;br /&gt;sometimes the /tlb option does the trick.&lt;br /&gt;&lt;br /&gt;If this doesn't fix the problem check the version number of the component on which your component depends on. If the components, on which your component depends, are &lt;strong&gt;singed&lt;/strong&gt; with specific key and are of &lt;strong&gt;specific version&lt;/strong&gt;, then your component also need to be signed with the &lt;strong&gt;same key&lt;/strong&gt; and versioned the same. Otherwise you will get the same automation error when loading from the component from a COM client. In .Net2.0 you update the AssemblyInfo.cs to update the version number and sign the component&lt;br /&gt;&lt;br /&gt;e.g.&lt;br /&gt;&lt;br /&gt;[assembly: AssemblyVersion("x.x.x.x")]&lt;br /&gt;[assembly: AssemblyFileVersion("x.x.x.x")]&lt;br /&gt;&lt;br /&gt;[assembly: AssemblyKeyFile(@"your_key.snk")]&lt;br /&gt;&lt;br /&gt;Hope this helps.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-8767770642279173564?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/8767770642279173564/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=8767770642279173564' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/8767770642279173564'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/8767770642279173564'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2007/11/automation-error-system-cannot-find.html' title='Automation Error System cannot find the file specified'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-1758998379467219455</id><published>2007-09-11T13:24:00.000-07:00</published><updated>2007-09-11T13:46:07.512-07:00</updated><title type='text'>Accessing network resource with in a Windows Service</title><content type='html'>Recently I ran into this problem where my windows service running under local system account could not access network resources such as shared folders. After googling a bit, I found Microsoft article that recommended running the service under "Network Service" account instead of System account when the service requires access to network resources. That sounds reasonable.&lt;br /&gt;&lt;br /&gt;After applying the changes run my service under Network Service account, I realized that now my service cannot access local files. That means the services running under Network service can only access network resources but not local resources. I am not sure what's the motivation behind it though.&lt;br /&gt;&lt;br /&gt;Next I tried creating a user defined account with the permission to access files both locally and remotely. I made my service to run under this new account. But still the service is not able to access network resources.&lt;br /&gt;&lt;br /&gt;If I convert the service to a standalone EXE and run it, it is able to access network resources.&lt;br /&gt;&lt;br /&gt;I have two more solutions to try. One of which is to update the windows service to impersonate another user through the code. Another solution is to map the driver within the service before accessing such drives. I am not sure how this might work out, I will keep you guys posted.&lt;br /&gt;&lt;br /&gt;If you have a solution, your input will be much appreciated.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-1758998379467219455?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/1758998379467219455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=1758998379467219455' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/1758998379467219455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/1758998379467219455'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2007/09/accessing-network-resource-with-in.html' title='Accessing network resource with in a Windows Service'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3826499523933116283.post-1371044299051415011</id><published>2007-07-24T06:38:00.000-07:00</published><updated>2007-07-24T07:33:02.541-07:00</updated><title type='text'>warning MSB3214: "*.dll" does not contain any types that can be registered for COM Interop.</title><content type='html'>Sometimes when a .Net assembly is made COM visible, you might still see MS Visual Studio 2005 complaining&lt;br /&gt;&lt;br /&gt;warning MSB3214: "*.dll" does not contain any types that can be registered for COM Interop.&lt;br /&gt;&lt;br /&gt;We know we can make a assembly COM visible by&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;adding [assembly: ComVisible(true)] in AsseblyInfo.cs&lt;/li&gt;&lt;li&gt;specifying [ComVisible(true)] attribute for the classes that need to be made com visible&lt;/li&gt;&lt;li&gt;and also checking the "Register for COM interop" option in project properties window under Build tab&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;After all these changes you might see Studio still not able to create the TLB for the assebly. In other words not able to register the assebly for COM interop.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Resolution:&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;I have not found the actual cause of the problem. But following workarounds have fixed the problem&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Somtimes closing the project and then reloading fixes the problem.&lt;/li&gt;&lt;li&gt;Open the command prompt and try registring the component with regasm command. Makre sure you are using the /tlb option. Without it you would get &lt;strong&gt;RegAsm : warning RA0000 : No types were registered&lt;/strong&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;The command would look something like &lt;/p&gt;&lt;p&gt;&lt;strong&gt;C:\Program Files\Microsoft Visual Studio 8\VC&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;regasm&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;asseblyname&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;dll&lt;/span&gt; /&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;tlb&lt;/span&gt;&lt;/strong&gt; &lt;/p&gt;&lt;p&gt;If someone knows the actual cause please let me know&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3826499523933116283-1371044299051415011?l=hoy-sala.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://hoy-sala.blogspot.com/feeds/1371044299051415011/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3826499523933116283&amp;postID=1371044299051415011' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/1371044299051415011'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3826499523933116283/posts/default/1371044299051415011'/><link rel='alternate' type='text/html' href='http://hoy-sala.blogspot.com/2007/07/warning-msb3214-dll-does-not-contain.html' title='warning MSB3214: &quot;*.dll&quot; does not contain any types that can be registered for COM Interop.'/><author><name>BinduSara</name><uri>http://www.blogger.com/profile/01434291526591343997</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
