Visual C++ Debugging Error - wuser32.pdb not loaded - visual-c++

I have made a form (GUI) in Visual C++ & while debugging it step by step, I got the following error, which stopped further debugging of the code.
The screenshot of the error is shown below.
How to solve this?

Good chance further debugging is in fact not stopped - seems you tried to step into a system function (implemented in wuser32.dll), and you can't debug this without matching symbols. You can post a screenshot of the stack window at this point to help us verify.
First, try to just continue (F5 or Shift+F11 to step out).
If for some reason you must view at least function names at this location - check the 'microsoft symbol server' at the screen you show. and click load. After a brief download pause, you should be able to see at least a disassembly window, and hopefully a meaningful name for the current stack frame.

Related

"Run|Debug" Buttons Not Appearing on Visual Studio Code Java Programs

A couple days ago I tried to initialize Visual Studio Code to be able to code in C++ using online instructions. They ended up not working at all, but I had edited some settings files (such as a .json file) in Visual Studio Code that I thought were all C++ specific. Afterwards, however, I no longer have the convenient "run | debug" buttons appearing above any "main" functions that I make in java files. In the past I used to be able to just click run and my program would run in the terminal at the bottom of the screen, as opposed to manually compiling and running the program using a terminal. I am running Windows 10. Does anyone know of any way to get these buttons back?
This is an example of what the two buttons look like, appearing above any main functions in a java program.
I also found on the Visual Studio Code website a description of how to begin debugging, attached here, that describes that you need Language Support for Java(TM) by Redhat in order to get these two buttons. I have this extension downloaded, but it is still not working. Please help if you recognize this issue!
What worked for me:
Make sure you have Java extensions, Java Debugger and other basic Java packages installed.
Then making sure the main function is formatted properly like below allowed the Run|Debug buttons to be seen.
public static void main(String[] args) {}
First of all, for troubleshooting, actually we need to have a reproduce steps which can understand what happened in your environment. So can you tell us what you have done to your settings first?
Second, there is a setting under common setting tab, that is Java>Debug>Settings>Enable Run Debug Code Lens. Please check whether this option has been unchecked. Although I think it should not be changed by you.

can't get logcat to work android studio

I've been trying to figure out why my app isn't working, but I can't find Logcat! I just uploaded the new Android Studio release. I've researched and found out where to look to get this message:
ddms: Can't bind to local 8610 for debugger
All the answers I see on SO are for Eclipse. I looked at the developer page, yet for DDMS, it sends you to another page that is full of information for running DDMS in Eclipse!
Please, need some help here! I mean if the dev page is wrong, can't someone show a little love? (Instead of knocking me down 4 points like yesterday. should left in the note I couldn't find my logcat but I was embarrassed.... now not so much .... )
thanks in advance.
I had to open the Android Device Manager to get at the Logcat. It would not scroll through the regular window when the app quit working like it used to (previous to yesterday's and today's updates to Android Studio). As such, I cannot copy and paste code, but can use snagit to capture pngs to post. Thank you. This question is closed.
Check if you have hided it...If it is hiding problems the go through given image to display it or ALT + 6

How to fix Visual Studio debugger watch window showing decompiled values

I have recently installed the RTM version of VS 2012, and when I run the debugger the watch window gives me what appears to be a decompiled vision of the local values. My initial thought was that I accidently hit the "Hexadecimal" display, but that is not the case. When I try to look at sub-properties off a given object, I get nothing, not even a representation if the object is null.
I won't know exactly what I may have set that is causing this, but VS 2010 did not do this, and the first day with VS2012RTM also didn't do this. I'm reasonably certain this is a setting I clicked, but for the life of me I can't figure out what it is.
Here are a couple screen shots of what the watch window looks like, and my debugging settings. As an aside, I have tried resetting my settings to factory, and turning IntelliTrace on and off.

LINK : fatal error LNK1104: cannot open .exe

My question is not a duplicate of this, in fact its a extension of the same question,
This is the code snippet, due to which the error occurs,
BOOL CMyApp::InitInstance() {
m_pMainWnd = new CMainWindow;
m_pMainWnd->ShowWindow(SW_NORMAL);
m_pMainWnd->UpdateWindow();
return TRUE;
}
So, when I use m_pMainWnd->ShowWindow(SW_NORMAL); the prgoram runs without any error, the window opens in normal size and I can see the output, but when I do m_pMainWnd->ShowWindow(SW_MAX); even after the program runs without errors I cannot see the output window, also when I try to rebuild, VC throws an error saying
LINK : fatal error LNK1104: cannot open .exe
I have followed a few answers of this question as well, the first answer in this question suggests
You might have not closed the the output. Close the output, clean and rebuild the file. You might be able to run the file now.
which is quite correct but what I have to do is log off my computer and log in again in order to terminate the output process, I have to do this because I can neither find an application window that is open, nor I can see any program running in the Application's tab in 'Task Manager'. I even followed the second answer which says
You have to put Application Experience on Manual startup(you can do it by searching services in windows 7 start menu, and then find Application Experience and click properties).
except when I got there, I found the Application was already put on Manual Startup, and the problem still persists. Along with the solution what I want to know is why does the program not show output when I write m_pMainWnd->ShowWindow(SW_MAX);
If it helps I am using VC++ 6.0 and my OS is Windows-7 Professional 32-bit
SW_MAX is same as SW_FORCEMINIMIZE the documentation states that
Minimizes a window, even if the thread that owns the window is not
responding. This flag should only be used when minimizing windows from
a different thread.
It infact minimize the window and the application still run's in the task bar. I checked it in Win7 machine.
if your objective is to display the window in maximized state use SW_SHOWMAXIMIZED instead.
The VC++ 6.0 debugger does not work correctly under Windows 7 due to changes.
When you attempt to kill the process from the debugger, the process doesn't end correctly and gets stuck.
See the following topic for more info.
How to debug with Visual C++ 6 on Windows 7 x64?

System.ComponentModel.Design.ExceptionCollection

I'm using the Ribbon control located on CodePlex, and following the tutorial located here . Once I add the reference, and the proper code in the designer I get this error when I try to view the form:
Exception of type 'System.ComponentModel.Design.ExceptionCollection' was thrown
And I cant figure out what I'm doing wrong. Anyone worked with this control and know how to resolve this issue?
Interesting; I just ran into this same issue with one of my own forms; which is how I found your relevant and recent question.
Here's how I solved it:
Open two instances of Visual Studio. Open the same project in both.
In one instance, goto Debug->Exceptions and enable all the 'Thrown' options to stop at first chance exceptions. This will stop the debugger when the exception is generated.
In the same instance, select Debug->Attach to Process, select devenv.exe.
In the other instance, open the form to cause the exception
With any luck the first instance should stop somewhere that yields a more relevant exception.
In my case it turned out to be something that I should have conditioned with:
if (!DesignMode)
{
// Do something that should only happen at runtime
}
Don't forget turn turn off all those 'Thrown' options later.
A workaround for me was:
Right-click on the form and 'View Code'
Keep the code loaded in the editor and then attempt to view the designer again.
This feels very glitchy and I cannot confirm whether it's a problem with my code (as I'm working on an entirely new codebase) or whether it's a VS2012 bug. If I find out, I will report back.
Since the solution outlined by pilotcam didn't work for me, I took a different approach:
Make a SVN commit for the file.
Open the “*.designer.cs” file of the form that shows the error in source view.
Remove larger blocks of form element declarations.
Fix all compilation errors with ReSharper (i.e. ensure that nothing is red anymore on the side-indicator).
Save the file. No need to compile.
Open the Windows Forms Designer of the form.
If the error still shows up, do a SVN revert to go back to the initial state.
Repeat steps 2 to 7 until the error does not show up anymore.
Now you’ve encircled the erroneous child control that causes the error.
Repeat steps 2 to 7 with a smaller amount of controls you remove, until you have only one control left.
In my case it was a user control inside a group control inside a tab control, so I first identified the tab control, then the group control and then the user control.
You could isolate the user control inside a new form to further investigate. In my case it was rather easy; I put checks for design mode around most of the functions inside my control to ensure the code only gets executed if the control is not in design mode.
This fixed my error.
I had the same issue and none of the above answers solved the problem.
At the end, emptying the "bin" folder and rebuild has worked for me.
Let me add two more cases when such exception can happen, along with when control tries to do something that is not allowed under design mode:
When it's impossible to compile the user control.
When designer code contains multiple similar (or identical) lines with initialization of same controls or properties, this can easily happen on merge.
All that cases produce same extremely meaningful error message, and in this particular two debugging of Visual Studio won't help, so I just ended up with bisecting my designer code.
[ReadOnly(true)]
[Browsable(false)]
Above all properties worked for me

Resources