SharpDevelop Community

Get your problems solved!
Welcome to SharpDevelop Community Sign in | Join | Help
in Search

Exception from "Find missing resource keys"

Last post 04-10-2007 5:55 PM by Christian Hornung. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 04-06-2007 1:43 AM

    Exception from "Find missing resource keys"

    This took worked a short time ago when I had several projects in a solution open, but it looked for missing keys in all projects, not just the current project. Handy, but it gave me a longer report than I was looking for. Shortly later, I opened one project by itself, and the tool gave me this exception. It happens every time, at least in this project. 

    SharpDevelop Version : 2.1.0.2462
    .NET Version         : 2.0.50727.42
    OS Version           : Microsoft Windows NT 5.1.2600 Service Pack 2
    Current culture      : English (United States) (en-US)
    Working Set Memory   : 63136kb
    GC Heap Memory       : 17359kb

    Exception thrown:
    System.NullReferenceException: Object reference not set to an instance of an object.
       at ICSharpCode.SharpDevelop.Dom.Refactoring.VBNetCodeGenerator.CreateOutputVisitor()
       at ICSharpCode.SharpDevelop.Dom.Refactoring.NRefactoryCodeGenerator.GenerateCode(AbstractNode node, String indentation)
       at Hornung.ResourceToolkit.Resolver.NRefactoryAstCacheService.ResolveLowLevel(String fileName, Int32 caretLine, Int32 caretColumn, CompilationUnit compilationUnit, String expressionString, Expression expression, ExpressionContext context)
       at Hornung.ResourceToolkit.Resolver.PositionTrackingAstVisitor.Resolve(Expression expression, String fileName)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResourceManagerInitializationFindVisitor.TrackedVisit(ObjectCreateExpression objectCreateExpression, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression, Object data)
       at ICSharpCode.NRefactory.Ast.ObjectCreateExpression.AcceptVisitor(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Visitors.AbstractAstVisitor.VisitVariableDeclaration(VariableDeclaration variableDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.TrackedVisit(VariableDeclaration variableDeclaration, Object data)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResourceManagerInitializationFindVisitor.TrackedVisit(VariableDeclaration variableDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.VisitVariableDeclaration(VariableDeclaration variableDeclaration, Object data)
       at ICSharpCode.NRefactory.Ast.VariableDeclaration.AcceptVisitor(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Visitors.AbstractAstVisitor.VisitFieldDeclaration(FieldDeclaration fieldDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.TrackedVisit(FieldDeclaration fieldDeclaration, Object data)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResourceManagerInitializationFindVisitor.TrackedVisit(FieldDeclaration fieldDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.VisitFieldDeclaration(FieldDeclaration fieldDeclaration, Object data)
       at ICSharpCode.NRefactory.Ast.FieldDeclaration.AcceptVisitor(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Ast.AbstractNode.AcceptChildren(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Visitors.AbstractAstVisitor.VisitTypeDeclaration(TypeDeclaration typeDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.TrackedVisit(TypeDeclaration typeDeclaration, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.VisitTypeDeclaration(TypeDeclaration typeDeclaration, Object data)
       at ICSharpCode.NRefactory.Ast.TypeDeclaration.AcceptVisitor(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Ast.AbstractNode.AcceptChildren(IAstVisitor visitor, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.TrackedVisit(CompilationUnit compilationUnit, Object data)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResourceManagerInitializationFindVisitor.TrackedVisit(CompilationUnit compilationUnit, Object data)
       at ICSharpCode.NRefactory.Visitors.NodeTrackingAstVisitor.VisitCompilationUnit(CompilationUnit compilationUnit, Object data)
       at ICSharpCode.NRefactory.Ast.CompilationUnit.AcceptVisitor(IAstVisitor visitor, Object data)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResolveResourceSet(IMember member)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.ResolveResource(ResolveResult resolveResult, Expression expr)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.Resolve(ExpressionResult expressionResult, Expression expr, ResolveResult resolveResult, Int32 caretLine, Int32 caretColumn, String fileName, String fileContent, IExpressionFinder expressionFinder, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.Resolver.BclNRefactoryResourceResolver.Resolve(ExpressionResult expressionResult, Expression expr, ResolveResult resolveResult, Int32 caretLine, Int32 caretColumn, String fileName, String fileContent, IExpressionFinder expressionFinder, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.Resolver.NRefactoryResourceResolver.TryResolve(ExpressionResult result, Expression expr, Int32 caretLine, Int32 caretColumn, String fileName, String fileContent, IExpressionFinder expressionFinder, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.Resolver.NRefactoryResourceResolver.Resolve(String fileName, IDocument document, Int32 caretLine, Int32 caretColumn, Int32 caretOffset, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.Resolver.AbstractResourceResolver.Resolve(String fileName, IDocument document, Int32 caretLine, Int32 caretColumn, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.ResourceResolverService.Resolve(String fileName, IDocument document, Int32 caretLine, Int32 caretColumn, Nullable`1 charTyped)
       at Hornung.ResourceToolkit.Refactoring.ResourceRefactoringService.FindReferences(IResourceReferenceFinder finder, IProgressMonitor monitor)
       at Hornung.ResourceToolkit.Commands.FindMissingResourceKeysCommand.Run()
       at ICSharpCode.Core.MenuCommand.OnClick(EventArgs e)
       at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
       at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
       at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
       at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
       at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
       at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ToolStrip.WndProc(Message& m)
       at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

    Filed under:
  • 04-10-2007 5:55 PM In reply to

    Re: Exception from "Find missing resource keys"

    I filed an issue: SD2-1348

    There is still a rather obscure issue with initialization of the code generator options.

    However, this should work if you opened a source code file before running "Find missing resource keys".

     

    Christian 

Page 1 of 1 (2 items)
Powered by Community Server (Commercial Edition), by Telligent Systems
Don't contact us via this (fleischfalle@alphasierrapapa.com) email address.