none
Duplicate Dataset Designers RRS feed

  • Question

  • I am having an issue where each time I make a change to my dataset and save it, the changes are saved as datasetname1.designer instead of datasetname.designer and the projectname.vbproj file has the following code added to it:

    <Compile Include="DataSetName1.Designer.vb">

          <AutoGen>True</AutoGen>

          <DesignTime>True</DesignTime>

          <DependentUpon>DataSetName.xsd</DependentUpon>

        </Compile>

     

     

         <LastGenOutput>DataSetName1.Designer.vb</LastGenOutput>

    My application then generates over 102 errors because it is recognizing duplicates of all the code in the designer. I've been able to work around this by deleting the original dataSetName.Designer file, renaming DataSetname1.designer as DataSetName.Designer and modifying my ProjectName.vbproj file to remove the above code. However, this only works until the next time I change and save the dataset when it all happens again.

    I've posted this in both:
    http://social.msdn.microsoft.com/Forums/en-US/winformsdatacontrols/thread/f2a9db6d-90d8-46ae-9b1b-74f17a04697f
    and
    http://social.msdn.microsoft.com/Forums/en-US/winformsdatacontrols/thread/8ab0d146-0cbb-47fc-880b-533fe8c55455

    but have not gotten any solutiions.

    Any help would be greatly appreciated.

    Wednesday, June 10, 2009 7:25 PM

All replies

  • Hi MethodMas,

    You should not directly make changes to DataSetName.Designer.vb, because this file is maintained by DataSet designer and is not supposed to be touched by users. Each time you modify the DataSetName.xsd file, DataSetName.Designer.vb will be re-generated and all your changes will be lost.

    Instead, add you changes to DataSetName.vb. Double click on DataSet designer (or any DataTable or DataTableApdater on DataSet designer), DataSetName.vb will be auto-generated and a partial class is defined. You should make all your changes here.

    Hopes it helps, thanks!
    Tuesday, June 16, 2009 3:17 AM
  • the only reason I have touched these files outside of the designer is because of the eratic behavior that is happening. deleting them outside the designer is the only workaround I've found.
    Monday, June 22, 2009 4:20 PM
  • What is the version of your Windows and Visual Studio? Could you propose the most simple steps to re-pro this issue?  e.g.
      1. create a VB winforms project
      2. add a new DataSet
      3. ......
      4. Save the changes
      [Actual Behavior] The changes are saved as datasetname1.designer.vb . . .
    Wednesday, June 24, 2009 2:30 AM