none
Error when my dll is called by parent application. MS.Win32.UnsafeNativeMethods.GetWindowText

    Question

  • I have an dll that is used by another application that gets the following error but only for some people and some time.  I don't even know where to start looking.  The dll was developed on VS2012 and is WPF.

    at MS.Win32.UnsafeNativeMethods.GetWindowText(HandleRef hWnd, StringBuilder lpString, Int32 nMaxCount)

       at System.Windows.Automation.Peers.WindowAutomationPeer.GetNameCore()

       at System.Windows.Automation.Peers.AutomationPeer.UpdateSubtree()

       at System.Windows.ContextLayoutManager.fireAutomationEvents()

       at System.Windows.ContextLayoutManager.UpdateLayout()

       at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)

       at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork()

       at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()

       at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)

       at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)

       at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)

       at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)

    my dll is used by another vendor's application which is designed to allow it to call custom applications within it and has classes and interfaces exposed for use by these custom applications.  I know this is kind of weak information and question but I am hoping someone can point me in the right direction.

    Friday, May 29, 2015 3:47 PM

Answers

  • Hi Michael Fetros,

    Based on your description, I’m afraid that it is not the correct forum for this issue, since this forum is to discuss:

    Visual Studio WPF/SL Designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System, and Visual Studio Editor.

    To make this issue clearly and help you find a more appropriate forum, would you mind letting us know more information about this issue?

    You said that you call this WPF dll file in an App, if so, which kind of app did you create?

    >>at MS.Win32.UnsafeNativeMethods.GetWindowText(HandleRef hWnd, StringBuilder lpString, Int32 nMaxCount).

    I did some research about the "GetWindowText", I got some information here:

    https://msdn.microsoft.com/en-us/library/windows/desktop/ms633520(v=vs.85).aspx

    So now the real issue is that whether your project called the GetWindowText function, if so, where did you use this function, in your current app or the WPF dll file? We have to know that whether it is related to your current app or the WPF dll file now, so I could help you find the correct forum for this issue.

    Best Regards,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Monday, June 01, 2015 7:04 AM