Bug 3164 - Mono for Android generated Resources file does not update when open in MonoDevelop
Summary: Mono for Android generated Resources file does not update when open in MonoDe...
Status: RESOLVED DUPLICATE of bug 2751
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: General ()
Version: 2.8.6
Hardware: Macintosh Mac OS
: --- major
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-01-31 14:00 UTC by Eric Beisecker
Modified: 2012-09-20 12:45 UTC (History)
2 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED DUPLICATE of bug 2751

Description Eric Beisecker 2012-01-31 14:00:52 UTC
Current Behavior: After updating the String.xml file in a Mono For Android project and rebuilding, the Resource.designer.cs file does not update if it is currently Open in MonoDevelop

Expected Behavior: The Resource.designer.cs file should always be updated after building the project when new Strings are added the Strings.Xml file

Steps to Reproduce:

1) Create a MfA project
2) Open the Resource.designer.cs file in MonoDevelop
3) Add a new String t othe Strings.xml file
4) Rebuild the Application

The newly added string will NOT appear in the Resource.designer.cs file

Versions: 
MonoDevelop 2.8.6.3
Mono 2.10.8
Mono for Android: 4.0.3.85258578
Comment 1 Eric Beisecker 2012-01-31 16:22:29 UTC
Increasing Severity of this Issue.

Is seems like this also affects a the ease of changing String value names. A user can change the name of a String resource in the String.xml and Autocomplete will NOT show the new String name.

Example:

Create new MfA project.

In Strings.xml
Add <string name="str1">Str Value</string>

In Main.axml
Add <Button android:id="@+id/btn" android:text="@string/str1"/>

In Activity1.cs
*After SetContentView*
var btn = FindViewById<Button>(Resources.Id.btn);
btn.SetText(Resource.String.str1);

Compile

Now change the Name of the String resource in Strings.xml to str2
Update the button in Main.axml to reference str2

Compile

MonoDevelop will have a build error since We didn't change Activity1.cs to Reference the new Str2 name.
but when trying to Change btn.SetText(Resource.String.str1) to btn.SetText(Resource.String.str2) Autocomplete does not show the new Str2 value.


Video: http://screencast.com/t/x9lFRQbHebph
Comment 3 Mikayla Hutchinson [MSFT] 2012-01-31 17:43:04 UTC
Oops, wrong bug.

*** This bug has been marked as a duplicate of bug 2751 ***