I'm not a bug expert hence y'all shouldn't yell at me if what I am about to say isn't what I should be saying. Here is the situation. I'm building a desktop windows form application in C# using VS 2010 Ultimatum. I added a new user control which contains a picture box that should display an image when some PropertyChangedEventHandler is fired. The application itself works as expected: No compilation error and when I run it, it does what it was meant to do. However VS is acting weird. Indeed, when I open the project in VS, it gives me this message:
I thought maybe my VS installation is corrupted. I reinstalled it, and opened the project again but the same happens. Strangely, if I comment out some code that invoke the PropertyChangedEventHandler , then VS would start and work normally. Is this supposed to be a VS bug? After all, it should at least complain that my code isn't supported but it shouldn't crash just because I wrote some bad code. Besides, if my code compiles and works as expected, can someone please tell me what's wrong?
P.S: Below is the details of the error as shown by VS. I'm looking to hear what you think.
Problem Event Name: CLR20r3
Problem Signature 01: devenv.exe
Problem Signature 02: 10.0.30319.1
Problem Signature 03: 4ba1fab3
Problem Signature 04:<<<<<Hiden for privacy issues>>>>> (It is just the one the namespace where the error comes from! )
Problem Signature 05: 1.0.0.0
Problem Signature 06: 4f288861
Problem Signature 07: 25
Problem Signature 08: 1
Problem Signature 09: System.DllNotFoundException
OS Version: 6.1.7600.2.0.0.256.4
Locale ID: 1033
Additional information about the problem:
LCID: 1033
I have also posted the same thread at MSDN forum
You need to disable PropertyChangedEventHandler from firing in Design mode.
If this is C#, it should look like this:
if(!this.DesignMode)
{
PropertyChanged(this, e);
}
If not that specifically, then disable whatever features might be causing the error from triggering in DesignMode.
Related
I'm working on a Direct2D (XAML) application (I picked this because I haven't done it before and I wanted to try it out, I thought it would be simple).
I created the project in Visual Studio 2012 using the default options.
I added a button to the GUI successfully.
I added a button press handler to the GUI successfully.
The problem is that I need the button press handler to send a registered windows message. I #include <Windows.h> as instructed by the MSDN docs for ::RegisterWindowMessage(), and finding the declaration and definition of the function with the F12 key works fine.
However, building the project fails, because the compiler can't find the function. Intellisense also flags the function as unrecognized.
I'm probably missing something in the project configuration, but I don't even know where to begin.
Can you please help me?
Edit: The exact error messages that I'm getting are:
error C2039: 'RegisterWindowMessage' : is not a member of '`global namespace''
error C3861: 'RegisterWindowMessage': identifier not found
RegisterWindowMessage is not available in a UWP application (which is likely what you are targeting in a XAML application). If you look into WinUser.h, you'll find the declarations are wrapped inside a
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
guard. This API is available to desktop applications only. There is nothing you can do to make it work in a UWP application.
Please refer to the attached error message as while executing this word macro I am getting this:
The program used to create this object is forms. that program is either not installed on your computer or it is not responding. To edit this object, install forms or ensure that any dialog boxes in the forms are closed
Kindly let me know what could be the issue in it.
This error message might be related to a missing Office update. Please make sure that your Office installation is fully patched (or that at least the update mentioned in the below article is installed).
For a detailed explanation check this article on Microsoft's support website:
"Cannot insert object" error in an ActiveX custom Office solution after you install the MS14-082 security update
The question is - why is my VB6 IDE crashing (all of a sudden) and how can I fix it?
VB6 had been operating on this PC, normally, for months if not years before this first began. The problem appeared to arise spontaneously.
Here's all the information I have to describe the issue...
Scenario:
Run VB6 - either by double clicking a project (VBP) file, or from it's icon / Start menu
Load a project
Try to open any form or code module
IDE instantly crashes with an error message such as:
An unhandled win32 exception occured in VB6.EXE [XXXX].
Allowing Windows to open the debugger, it shows the fault occurring on this line:
004581F1 mov ecx,dword ptr [eax]
And in the Windows event log, it shows this:
Problem signature:
Problem Event Name: APPCRASH
Application Name: vb6.exe
Application Version: 6.0.97.82
Application Timestamp: 403acf6c
Fault Module Name: vb6.exe
Fault Module Version: 6.0.97.82
Fault Module Timestamp: 403acf6c
Exception Code: c0000005
Exception Offset: 000afa89
OS Version: 6.2.9200.2.0.0.256.48
Locale ID: 1033
Additional Information 1: a239
Additional Information 2: a239f58f940977df1cec7176d1176bff
Additional Information 3: ef99
Additional Information 4: ef9908a42708e3d51b1220b5874297f1
O/S: Win7 64 bit
Note 1 - I think this is a different issue than this question: VB6 crashes after build, because the scenario to cause the crash is different.
Note 2 - I have seen a few signs of this problem elsewhere. Both here and here include some similar information, but no apparent solution.
Ultimately I found that I needed to reset the compatibility settings of VB6.exe.
Specifically:
Go to C:\Program Files (x86)\Microsoft Visual Studio\VB98
Right click vb6.exe, right click, and select Properties
Select Compatibility tab
Mine was already set to run in Win XP compatibility mode. Uncheck this.
Close properties.
Run the EXE. Still not fixed.
Open properties. Set Win XP compat again.
Run VB6. Open project. Open form. No crash.
Note that rebooting, reinstalling VB6 and the latest service pack, etc. had no effect on this issue, all of which I tried before stumbling into this solution.
I cannot get my Outlook addin to work in release mode for OL2007 (debug works great). I created a ClickOnce installer, signed it with a custom certificate and built the installer.
Then after installation when I start Outlook 2007, it does not load and gives no notification at all. I look into the addin section where I find my addin among "inactive addins". I look to the COM addins and find it unchecked (checking it doesn't help) with the notification "Not loaded" (NOTHING ELSE).
Things I tried already:
try/catch block around my startup routine plus message output: nothing is shown
new custom signing certificate: useless
APPDATA\MS\Outlook\extend.dat deleted: to no avail
regedit setting "LoadBehaviour" 3: It is always like that, I don't have to change it
VSTO_SUPPRESSDISPLAYALERTS = 0: to no avail, nothing is shown
VSTO_LOGALERTS = 1: same here, nothing is logged
Fusion Logging: nothing is posted into the output directory
I get NO info at all what causes my addin not to load. It is driving me crazy. Can anyone point me to a solution or at least something I can still try to solve this problem?
The problem obviously occurred due to a difference between GUID and setup product key. Changing the setup product key to match the GUID enabled the addin to complain about errors again, so I could continue with debugging.
Very weird that in this case no error whatsoever was thrown.
I've installed Visual Studio 15.9.0, Preview 3 and created a project using the new platform support for C++/winrt. The project runs fine until I set a breakpoint. When the break is hit VS tells me "You need to find debuggerutils.h to view the source for the current call stack frame" It tells me this file was originally at onecore\com\combase\inc\debuggerutils.h, though it doesn't tell me the path to onecore. Search can't find such a file. Does anyone know how to find that file or install it? I had just assumed that VS would automatically include debugging capability.
[Update] Appears it is not the setting of a breakpoint but a bug causing a break before that. But I'm still mystified by the error message.
Someone asked this question on github's WinObjC issues:
https://github.com/microsoft/WinObjC/issues/2931
From the discussion:
edvv commented on Nov 22, 2019
Ah, now I remember what this means: "This is a false message. What really happened is that your app silently terminated (maybe by a console abort(), i.e.: crashed ) and when the app failed to launch (aborted) the front end gave that message. You need to look at the Windows Console window in VS while in debug mode."