Bug 12922 - cannot add a new file to Assets/js
Summary: cannot add a new file to Assets/js
Status: RESOLVED NORESPONSE
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Android Add-in ()
Version: 4.0.9
Hardware: PC Windows
: --- normal
Target Milestone: master
Assignee: Greg Munn
URL:
: 12919 ()
Depends on:
Blocks:
 
Reported: 2013-06-27 14:33 UTC by Tim Jowers
Modified: 2015-01-07 16:12 UTC (History)
2 users (show)

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


Attachments
project file (20.51 KB, text/plain)
2013-08-29 15:45 UTC, Tim Jowers
Details
user proj (320 bytes, text/plain)
2013-08-29 15:45 UTC, Tim Jowers
Details
sln (1.66 KB, text/plain)
2013-08-29 15:46 UTC, Tim Jowers
Details
suo (106.50 KB, application/octet-stream)
2013-08-29 15:46 UTC, Tim Jowers
Details


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 NORESPONSE

Description Tim Jowers 2013-06-27 14:33:24 UTC
Get:
System.ArgumentNullException: Value cannot be null.
Parameter name: path2
   at System.IO.Path.Combine(String path1, String path2)
   at MonoDevelop.Core.FilePath.Combine(String[] paths)
   at MonoDevelop.MonoDroid.MonoDroidProject.GetDefaultBuildAction(String fileName)
   at MonoDevelop.Ide.Templates.SingleFileDescriptionTemplate.AddFileToProject(SolutionItem policyParent, Project project, String language, String directory, String name)
   at MonoDevelop.Ide.Templates.SingleFileDescriptionTemplate.AddToProject(SolutionItem policyParent, Project project, String language, String directory, String name)
   at MonoDevelop.Ide.Templates.FileTemplate.CreateFile(FileDescriptionTemplate newfile, SolutionItem policyParent, Project project, String directory, String language, String name)
   at MonoDevelop.Ide.Templates.FileTemplate.Create(SolutionItem policyParent, Project project, String directory, String language, String name)
   at MonoDevelop.Ide.Projects.NewFileDialog.OpenEvent(Object sender, EventArgs e)
Comment 1 Tim Jowers 2013-06-27 14:37:46 UTC
File is actually created on the disk but not added in Xamarin. So, no way to add Assets to this project any more. It was imported. Maybe the other project was an older version of Xamarin? who knows.
Comment 2 Tim Jowers 2013-06-27 14:39:40 UTC
Work-around is to Add File from "Assets"... then one can select js/file.js and then add. then have it kept in its own directory.
Comment 3 Mikayla Hutchinson [MSFT] 2013-07-01 15:29:16 UTC
I cannot reproduce this. Could you please attach the project file?
Comment 4 Tim Jowers 2013-08-29 15:40:48 UTC
Trying to import directory:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentNullException: Value cannot be null.
Parameter name: path2
   at System.IO.Path.Combine(String path1, String path2)
   at MonoDevelop.Core.FilePath.Combine(String[] paths)
   at MonoDevelop.MonoDroid.MonoDroidProject.GetDefaultBuildAction(String fileName)
   at MonoDevelop.Ide.ProjectOperations.AddFilesToProject(Project project, FilePath[] files, FilePath[] targetPaths, String buildAction)
   at MonoDevelop.Ide.Gui.Pads.ProjectPad.FolderCommandHandler.AddFilesFromFolder()
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   at MonoDevelop.Components.Commands.DefaultCommandHandler.Run(Object target, Command cmd)
   at MonoDevelop.Components.Commands.CustomCommandTargetAttribute.Run(Object target, Command cmd)
   at MonoDevelop.Ide.Gui.Components.NodeCommandHandler.TransactedNodeHandlerAttribute.Run(Object target, Command cmd)
   at MonoDevelop.Components.Commands.CustomCommandTargetAttribute.MonoDevelop.Components.Commands.ICommandTargetHandler.Run(Object target, Command cmd)
   at MonoDevelop.Components.Commands.CommandHandlerInfo.Run(Object cmdTarget, Command cmd)
   at MonoDevelop.Components.Commands.CommandManager.<>c__DisplayClassb.<DispatchCommand>b__2()
   at MonoDevelop.Components.Commands.CommandManager.DispatchCommand(Object commandId, Object dataItem, Object initialTarget, CommandSource source)
Comment 5 Tim Jowers 2013-08-29 15:45:20 UTC
Created attachment 4751 [details]
project file
Comment 6 Tim Jowers 2013-08-29 15:45:45 UTC
Created attachment 4752 [details]
user proj
Comment 7 Tim Jowers 2013-08-29 15:46:11 UTC
Created attachment 4753 [details]
sln
Comment 8 Tim Jowers 2013-08-29 15:46:31 UTC
Created attachment 4754 [details]
suo
Comment 9 Tim Jowers 2013-08-30 16:53:51 UTC
*** Bug 12919 has been marked as a duplicate of this bug. ***
Comment 10 Tim Jowers 2013-09-05 08:04:12 UTC
Created a new solution from scratch and it works fine there.
Comment 11 Greg Munn 2015-01-07 16:12:14 UTC
There hasn't been any activity on this bug for quite some time. I'm going to mark it closed but feel free to re-open it if you feel it still needs attention.

Also, as this was only recently assigned to me, I did try to use the attached files but there are many missing files and I could not use them.