Why wouldn't it tell me what line there is a syntaxis error in?
When you build/compile your project, does it not display a list of errors and warnings in the "output" window ? do you see the output window ? When there is an error there should be something like that :
Are you talking about a compilation error or a runtime error ?
when debugging, the debugger will give you some information about the error it encounters :
- call stack (gives the call-context so you can trace-back the crash and see what function called what other function)
- local data (watch window to inpect variables, ...)
- output window (sometimes)
other than that, perhaps give us the error you get (copy'n'paste the error you get) and we can help you with that.
Yes, you compile a file/project and it will list the compilation errors in the output window, there, you can double-click on the error in the list and it will open the appropriate file and and go to the line in question.
it's been like that since a long time in Visual Studio ...
It's probably got more to do with C++ being a real bitch to parse - the VC++ development team ended up embedding the EGC C++ compiler front end in the IDE to detect errors as you type. There's a lot of compilation going on in there... shame they can't use their own compiler so that when you finish typing the new object file is ready to link.
so that when you finish typing the new object file is ready to link.
I suspect the overhead would be somewhat expensive. Personally I have no problem typing (some of) the source, running a compilation, then fixing all the syntax errors, before moving to the next piece of code.
I have written a code which takes the data out of the Matrix for an image and converts from RGB to Y component. My next step would be to split this matrix into 4x4 blocks and perform some calculations. After this, I want to take the resultant matrices and do some computations with the original Matrix. I am confused with the loops and how to go about creating the loops. I will be very glad if someone can help me with a code snippet. Thanks a lot.
Here is what I want to do. I have an image which I converted from RGB to Y component. Now I want to group the pixels into a 4x4 block. And then take an average for each block. And then subtract this with the original 4x4 block.
In the main program how do I make the nested loop. For examaple I assign Trow=128 and Tcol=128. Here Trow and Tcol are the total row and column.
1. I need to here scan through Trow * Tcol.
2. And take each block and perform the above function.
3. What will be the values for row and col in the above code?
4. does m[j][i] represent the original matrix?
Looks like you're trying to paint the control, and then immediately draw a solid rectangle over it.
RedrawWindow invalidates the client region of your window. The borders are not part of that region. Then the FillSolidRect code kicks in and fills the dialog background. Now the WM_PAINT from your RedrawWindow call comes to your list controls message pump, and it redraws the invalidated region, the client area, but not the border.
Thanks for all your help.I have found the solution.
I am reading all the character from combo and storing it in map.
then i am reading the character from combo and Find() in given whole map.
I am tryig this code
the problem i am facing is,
1)The first string is getting set in the ComboBox.
2)when i type the first character in combo,it is getting the strings
related to the first character.
but i am not able to type in the second character,as the cursor is going in the first position.
The character which i have typed later is going first.
For Ex: First i will type the character as "P",
Second if i type "A" character in combo,its going before "P"
i.e "AP",but i need as "PA".
I am bit confused,
You need to set the cursor position manually. If you are using MFC use CCoboBox::SetEditSel()[^] API, otherwise send the control the CB_SETEDITSEL[^] message. Set start and end char to be the length of your string.