|
I have a question about debugging in VC6.
When the IDE breaks at a location and you look at the variables window for the "Value" of a class if the class is descendent of a CObject you'll see the class name ex: {CMyObject} but for a CString, CRect, CPoint, etc. you'll see the value(s) of the most important member(s) of the class, CString - the actual string, CPoint - the X and Y coordinate.
So my question is: Is there a way to control the text in the value column or the variable window of the IDE for a class or is it the IDE that decides what to display?
For example if I created a CMyString class that's a descendent of a CObject class. When I debug in the "Value" column I only see {CMyString}, I always have to click on the "+" sign to see the value of the CMyString class. I would be very useful to have control on what the IDE would display for a value of a class.
But if the IDE decides what members is displayed for certain class, then I guess I would kind of be impossible to do...
Thanks...
Serge R
|
|
|
|
|
You have to edit this file:
(wherever you installed Visual)\Common\MsDev98\Bin\Autoexp.dat
Add a line like this:
CMyString=<membervariable>
Fortunately, there are (should be) some instructions within this file that explain exactly what you can do. I'd recommend closing down Visual before editing this file.
No generalization is 100% true.
Not even this one.
|
|
|
|
|
take a look here:
http://www.codeguru.com/tips/CustomizingDebug.shtml
|
|
|
|
|
I'm writing this code to control a mechincal syring and I keep getting this error when I try to build it.
header file: int pl32ComClose(void);
call fn in .cpp: pl32ComClose();
error recieved: myc32.obj : error LNK2019: unresolved external symbol "int __cdecl pl32ComClose(void)" (pl32ComClose@@YAHXZ) referenced in function _main
How do I go about fixing this? I'm using a predefined .lib and .dll file for the functions. Am I not linking correctly to the files? Am I calling it incorrectly?? Any help would be greatly appreciated.
|
|
|
|
|
Try including the header in your .cpp like this:
extern "C"{
#include "lpr32.h"
}
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
That is still not working. I include the header #include "Test32C.h" originally. I tried it this new way and the same error came up. Thanks for trying though. any other suggestions???
|
|
|
|
|
It's hard to say without further info:- Does it work if you link the DLL in a C-only project?
- Could it be the DLL was built for a different version of VC++ than you're using?
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Hello all,
I've been lurking here for quite a while and have run into a problem that I can't seem to find an answer to, so I thought I'd give you guys (and gals) a shot.
I'm trying to create a MAPI preprocessor using a minimal Transport Provider as described in the MAPI SDK. This Preprocessor is to be used in conjunction with Microsoft Exchange. According to the SDK, the Preprocessor method is *supposed* to be called from the MAPI spooler. In my case, it is not being called at all. There are a statements buried within the SDK documentation about the case of a tightly coupled Transport Provider and Message Store bypassing the MAPI spooler entirely.
"This implies that the individual parts within the combined service provider should interact with each other in a way that simulates the interaction they would normally have with the parts of the MAPI subsystem that are not being used." - directly from the Microsoft SDK.
What I suspect is that the Exchange provider is a tightly coupled Message Store and Transport, thus bypassing the spooler and not internally duplicating the spooler's behavior by calling other registered preprocessors.
Can anyone out there confirm, deny or perhaps point me somewhere to find out if this is in fact the case?
To answer the first wave of "Have you tried..." questions, here goes:
No, I can't use Hook providers as they only get called after a message is sent, I need to modify a message before it is sent.
No, I can't use Outlook Automation, it only works within the outlook client app, I need to grap ALL messages, not just those sent from within Outlook (besides, the Outlook automation is grossly incomplete and buggy).
Yes, my Transport Provider is being loaded, and logged into properly when a MAPI client (including Outlook) is used.
Thanks in advance for any light or dark that you might be able to shed on this...
PS. You guys (and gals) are pretty funny to sit back and watch.
George
|
|
|
|
|
I have a little problem with WinForms.
I've created a Managed C++ app. Then I wanted to add a WinForm but I couldn't find the appropriate function. So I decided to see the samples.
I find the solution but I still cannot use the designer as in C# or VB.Net.
Does anybody know how to add a WinForm to VC++.Net which can be modified in the designer.
Thanks in advance
|
|
|
|
|
Nish has some article about it.
http://codeproject.com/useritems/mcppwinforms01.asp
Mazy
"The path you tread is narrow and the drop is shear and very high,
The ravens all are watching from a vantage point near by,
Apprehension creeping like a choo-train uo your spine,
Will the tightrope reach the end;will the final cuplet rhyme?"Cymbaline-Pink Floyd
|
|
|
|
|
When calling GetOpenFileName w/ multi-select enabled, is there a way to determine the buffer space required by the lpstrFile pointer ?
|
|
|
|
|
I don't think so.
GetOpenFileName() returns FALSE if you specify a buffer that's too small. I ran into this annoying problem some time ago, and now always allocate a generous (64K) buffer when I call the multiselect version of GetOpenFileName() .
/ravi
"There is always one more bug..."
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
<click> This link is solution that works for win 98. I am trying to figure out how to do this with W2K without much luck so far.
---
CPUA 0x5041
Sonork 100.11743 Chicken Little
It may be that your sole purpose in life is simply to serve as a warning to others.
|
|
|
|
|
Hey guys
I have a list view control in report mode for a project im doing i want to be able to edit the text on sub items ie ones in not teh main column. I doesn't allow this is tehre away to enable this or am i gonna have to write a custom control.
Peter
|
|
|
|
|
See this article.
/ravi
"There is always one more bug..."
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
The code below generated some errors in linking:
#include "dao.h"
void main()
{
try
{
static CDaoDatabase *base = new CDaoDatabase;
base->Open("c:\\biblio.mdb");
CDaoRecordset *rst = new CDaoRecordset(base);
rst->Open(1, "select * from authors");
for(int i=0; i<5; i++)
{
printf("%d, %s\n", i+1, rst->GetFieldValue(1));
rst->MoveNext();
}
}
catch(CDaoException e)
{
}
}
--------------------Configuration: dao - Win32 Debug--------------------
Compiling...
dao.cpp
Linking...
nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __endthreadex
nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __beginthreadex
Debug/dao.exe : fatal error LNK1120: 2 unresolved externals
Error executing link.exe.
dao.exe - 3 error(s), 0 warning(s)
And the header file contains:
#include <stdio.h>
#include <afxdao.h>
Although I checked Microsoft Knowledge Base for Q126646, the problem hadn't been solved. Can somebody offer more suggections?
|
|
|
|
|
Are you linking with one of the multi-threaded CRT libraries?
LIBCMT.LIB or MSVCRT.LIB
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
I'm not sure at all, but I would have checked the Project Settings. Project menu -> Settings... -> C/C++ tab -> Category: 'Code Generation' -> Use run-time library: 'Multithreaded' (or 'Debug multithreaded' for debug mode)
Sprudling
|
|
|
|
|
Does anybody know how to give a service parameters at startup???
|
|
|
|
|
When you popup the property page for a given service, there is an edit box at the bottom that allows you to specify start parameters. This can only be done if the service is stopped.
Michel
It is a lovely language, but it takes a very long time to say anything in it, because we do not say anything in it, unless it is worth taking a very long time to say, and to listen to.
- TreeBeard
|
|
|
|
|
True, but this is pretty unusual way to handle service parameters. Usually, the parameters are placed in the registry, and services read them from there.
I vote pro drink
|
|
|
|
|
Using VC++, How to i write the output of a pipe to a text file?
Thanks
|
|
|
|
|
I could not find any thing specific to let you write the output directly from the pipe to a file, but since the Read and Write functions are the same for both apipe and a file in Win32, it should be fairly simple for you to read from a pipe, and turn right around and write the same data to a file.
If you wanted to reduce this to one step you memory map you file, and you will then recieve a pointer that you can pass into the pipe function. When you read the data from the pipe, you can access it from your mapped memory pointer, and when you are done, the data will already be written in your file.
Good Luck
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
For reasons which are too complex to talk about here , I want to develop and compile a static library with VC++ .net and then link it into a VC++ V6 app . I get lots of link errors. Anyone know if it is possible to do what I want ? I am kind of hopeing there is a compiler switch for the library. Also I make the library now with VC++ 6 and its 1.5 MB , recompile under VC++ .net and it goes up to 5.5MB , any ideas why ?
|
|
|
|
|
I've asked a question just like it.A russian shouted a lot of russian which i don't understand at me.I think there should be someone else knows about how to do it here.
modified 1-May-21 21:01pm.
|
|
|
|