app.config checkout when design a form
Moderator: SourceGear
app.config checkout when design a form
In VS 2010, when a developer starts to do design work on a form app.config is checked out. If a second developer tries to do design work on a different form in the same project, they are unable to do so if the first developer checked out app.config exclusively. If the first developer checked out app.config non-exclusively, the second developer appears to have the ability to work in the designer. However, any changes that are made are immediately undone when the developer moves on the next change. The only way we have found to get around this is to check in or undo check out of app.config after the form designer has opened. Note that this has to be done each time another form is opened. Why does VS 2010 and/or Fortress think that app.config needs to be checked out when form design work is done? The way that this works now, only one developer at a time can do form design work in a project at a time. Obviously this makes collaborative work nearly impossible. Any suggestions?
Re: app.config checkout when design a form
Are you using the Fortress Enhanced Client or the Fortress Classic Client?
Your users could either set their defaults to not do exclusive check-outs or change the method of development to be CVS style. Both of those settings are found in the Fortress Tools - Options. The first is under the General link and the second is under the Concurrent Development Style link.
Your users could either set their defaults to not do exclusive check-outs or change the method of development to be CVS style. Both of those settings are found in the Fortress Tools - Options. The first is under the General link and the second is under the Concurrent Development Style link.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: app.config checkout when design a form
We're using enhanced client.
As I stated in my original post:
If the first developer checks out app.config non-exclusively, the second developer appears to have the ability to work in the designer. However, any changes that are made are immediately undone when the second developer moves on to the next change.
In other words, doing non-exclusive check outs does NOT solve the problem. Any other suggestions?
As I stated in my original post:
If the first developer checks out app.config non-exclusively, the second developer appears to have the ability to work in the designer. However, any changes that are made are immediately undone when the second developer moves on to the next change.
In other words, doing non-exclusive check outs does NOT solve the problem. Any other suggestions?
Re: app.config checkout when design a form
Code: Select all
However, any changes that are made are immediately undone when the second developer moves on to the next change.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: app.config checkout when design a form
Sure. The simplest example:
Select and move a text box to another place on the form. The text box moves. Then click on another control on the form and the text box moves back to it original position. No, really it does! To me the more vexing question is why VS and/or Fortress think that app.config needs to be checked out when a form's design is edited. This implies some sort of relationship, but in looking at the project file I see no such relationship (and even if I did it wouldn't make any sense).
Select and move a text box to another place on the form. The text box moves. Then click on another control on the form and the text box moves back to it original position. No, really it does! To me the more vexing question is why VS and/or Fortress think that app.config needs to be checked out when a form's design is edited. This implies some sort of relationship, but in looking at the project file I see no such relationship (and even if I did it wouldn't make any sense).
Re: app.config checkout when design a form
What exact project type is this?
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: app.config checkout when design a form
It's a very large VB.Net WinForm project.
Re: app.config checkout when design a form
It turns out that this problem was with us before we converted to VS 2010. And, it may have even been a problem when we used Visual Source Safe for version control (before we switched to Fortress). Is there any information maintained by Fortress that might maintain this strange relationship between app.config and form design? Note: I created a new simple project from scratch using VS 2010 and it does NOT require me to check out app.config when I do design work on a form.
Re: app.config checkout when design a form
Have you compared the app.configs to see if they reference the files that you are changing or if there are any sections in the old one that aren't present in the new one?
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: app.config checkout when design a form
The app.config file does not reference any form files and in fact is pretty trivial. Here's the whole file:
<?xml version="1.0"?>
<configuration>
<configSections>
</configSections>
<appSettings>
<!-- User application and configured property settings go here.-->
<!-- Example: <add key="settingName" value="settingValue"/> -->
<add key="sqlconCssDbSrvr.ConnectionString" value="Data Source=APSCSVR8;Initial Catalog=dbCSSProduction;Integrated Security=True;Asynchronous Processing=true;MultipleActiveResultSets=True"/>
<add key="SOCName" value="Jan Sanders"/>
<add key="SOCEmailAddress" value="jan_sanders@psc.state.ar.us"/>
<add key="SOCPhone" value="(501) 682-5782"/>
<add key="SOCFax" value="(501) 682-1717"/>
<add key="APSCOnlineMain" value="http://www.apscservices.info/CSSDev/e-f ... rface.aspx"/>
<add key="APSCOnlineDocketSearch" value="http://www.apscservices.info/CSSDev/Mai ... px?Docket="/>
<add key="DesignationOrderDocument" value="c:\CSS_Docs\TempDesignation.doc"/>
<add key="DesignationOrderTemplate" value="c:\CSS_Docs\DesignationOrder.dot"/>
<add key="JudiciaryAssignmentEmailRecipient" value="mary_eagles@psc.state.ar.us"/>
<add key="CSSEmailSender" value="CSS.Notification@psc.state.ar.us"/>
<add key="EmailClientHost" value="APSCSVR12.APSC.local"/>
<add key="APSCWebMasterEmailAddress" value="webmaster@psc.state.ar.us"/>
<add key="CloseOrderDocument" value="c:\CSS_Docs\TempClose.doc"/>
<add key="CloseOrderTemplate" value="c:\CSS_Docs\CloseOrder.dot"/>
<add key="TariffStoragePath" value="\\apscsvr6\tariffstorage\"/>
<add key="TariffSupersededPath" value="\\apscsvr6\tariffsuperseded\"/>
<add key="TariffCancelledPath" value="\\apscsvr6\tariffcancelled\"/>
<add key="ReceivedDocStoragePath" value="\\apscsvr6\rcvddocs\"/>
<add key="AnnualReportStoragePath" value="\\apscsvr6\arreportstorage\"/>
<add key="PDFFStoragePath" value="\\apscsvr6\PDFF\"/>
<add key="PDFGStoragePath" value="\\apscsvr6\PDFG\"/>
<add key="AASISCustomerDocument" value="c:\CSS_Docs\TempAASIS.doc"/>
<add key="AASISCustomerTemplate" value="c:\CSS_Docs\AASISCUstomerForm.dot"/>
</appSettings>
<startup>
</startup>
</configuration>
EVERY form that I open in the designer causes app.config to be checked out. So there is clearly some information in VS or Fortress that causes this check out. It most definitely is NOT the project file. I have looked at it and the only app.config reference is:
<None Include="app.config" />
Currently I have Fortress configured to prompt to check out when an edit is required. When I make a change in the form designer, Fortress prompts me as it should. However, the list always includes app.config as well as the source, designer and resource files. How is this list created by Fortress? In other words, what information does it use to create the list? For some reason this information always directs Fortress to include app.config in the list. Is there anything I can do that will stop it from doing so?
<?xml version="1.0"?>
<configuration>
<configSections>
</configSections>
<appSettings>
<!-- User application and configured property settings go here.-->
<!-- Example: <add key="settingName" value="settingValue"/> -->
<add key="sqlconCssDbSrvr.ConnectionString" value="Data Source=APSCSVR8;Initial Catalog=dbCSSProduction;Integrated Security=True;Asynchronous Processing=true;MultipleActiveResultSets=True"/>
<add key="SOCName" value="Jan Sanders"/>
<add key="SOCEmailAddress" value="jan_sanders@psc.state.ar.us"/>
<add key="SOCPhone" value="(501) 682-5782"/>
<add key="SOCFax" value="(501) 682-1717"/>
<add key="APSCOnlineMain" value="http://www.apscservices.info/CSSDev/e-f ... rface.aspx"/>
<add key="APSCOnlineDocketSearch" value="http://www.apscservices.info/CSSDev/Mai ... px?Docket="/>
<add key="DesignationOrderDocument" value="c:\CSS_Docs\TempDesignation.doc"/>
<add key="DesignationOrderTemplate" value="c:\CSS_Docs\DesignationOrder.dot"/>
<add key="JudiciaryAssignmentEmailRecipient" value="mary_eagles@psc.state.ar.us"/>
<add key="CSSEmailSender" value="CSS.Notification@psc.state.ar.us"/>
<add key="EmailClientHost" value="APSCSVR12.APSC.local"/>
<add key="APSCWebMasterEmailAddress" value="webmaster@psc.state.ar.us"/>
<add key="CloseOrderDocument" value="c:\CSS_Docs\TempClose.doc"/>
<add key="CloseOrderTemplate" value="c:\CSS_Docs\CloseOrder.dot"/>
<add key="TariffStoragePath" value="\\apscsvr6\tariffstorage\"/>
<add key="TariffSupersededPath" value="\\apscsvr6\tariffsuperseded\"/>
<add key="TariffCancelledPath" value="\\apscsvr6\tariffcancelled\"/>
<add key="ReceivedDocStoragePath" value="\\apscsvr6\rcvddocs\"/>
<add key="AnnualReportStoragePath" value="\\apscsvr6\arreportstorage\"/>
<add key="PDFFStoragePath" value="\\apscsvr6\PDFF\"/>
<add key="PDFGStoragePath" value="\\apscsvr6\PDFG\"/>
<add key="AASISCustomerDocument" value="c:\CSS_Docs\TempAASIS.doc"/>
<add key="AASISCustomerTemplate" value="c:\CSS_Docs\AASISCUstomerForm.dot"/>
</appSettings>
<startup>
</startup>
</configuration>
EVERY form that I open in the designer causes app.config to be checked out. So there is clearly some information in VS or Fortress that causes this check out. It most definitely is NOT the project file. I have looked at it and the only app.config reference is:
<None Include="app.config" />
Currently I have Fortress configured to prompt to check out when an edit is required. When I make a change in the form designer, Fortress prompts me as it should. However, the list always includes app.config as well as the source, designer and resource files. How is this list created by Fortress? In other words, what information does it use to create the list? For some reason this information always directs Fortress to include app.config in the list. Is there anything I can do that will stop it from doing so?
Re: app.config checkout when design a form
Code: Select all
I created a new simple project from scratch using VS 2010 and it does NOT require me to check out app.config when I do design work on a form.
Does making a web reference in your test project make it suddenly want to check out the app.config?
Do you have any other config file being dependent upon app.config?
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: app.config checkout when design a form
The project is an old legacy VB project, where each form has a SqlConnection object. The connection string for the SqlConnection object is defined in app.config. The form designer file code gets the connection string by creating a System.Configuration.AppSettingsReader object and using the GetValue method on it. Because the designer interprets the code in the designer file to render the form graphically, this reference to app.config is apparently enough to force a check out of app.config. I got around the problem by using the VS settings GUI to create an app.config using the newer format in conjunction with the settings files. Now the form designer code gets the connection string using Global.<myProject>.MySettings.Default.<connectionStringName>. Now app.config is NOT checked out when changes are made to a form's design. Problem solved.
Last edited by rdoran on Wed Oct 27, 2010 10:35 am, edited 1 time in total.
Re: app.config checkout when design a form
Thank you for posting what you found. Some other user may find this helpful.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support