Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Circular file references are not allowed. Publish ASP.NET (2.0) Website

Tags:

c#

asp.net

When I re/build my ASP.NET website I do not receive any errors. However when I PUBLISH the site, it gives me a 'Circular file references are not allowed.' error.

I read a little on the web about this, and it provided a batch='false' option, which I tried and does nothing.

The page, has a master page, which may call on the same control twice; however, this control does not refer back to anything

TY - Theo

like image 604
Theofanis Pantelides Avatar asked Dec 30 '22 02:12

Theofanis Pantelides


1 Answers

Theo, I also received this error quite a few times which is very annoying, even though I searched for ages for circular file references I couldn't find any. In the end I decided that although there are no definite circular file references, the compiler did not like it when I referenced a control in a parent folder e.g. I have a control in the folder /UserControls/Panels/ManagerPanels/ which references a control in the folder /UserControls/Panels/. This works ok when coding but trying to publish or debug brought about the Circular file reference problem. Sorry to say the only solution I found was to move the referencing control back a folder into the same folder as the control it was referencing, this fixed the problem (although it is extremely frustrating as I like a nice folder structure for my controls, of which there are many). Hope this helps

like image 166
System24 Tech Avatar answered Jan 30 '23 10:01

System24 Tech