|
No conversion is nessasary
LPSTR pSomeStr;
LPCTSTR pConstSomeStr = pSomeStr;
|
|
|
|
|
Hi
I was wondering, does anybody know where i can find a c++ implementation of a B+ tree data structure. I've been looking through the web without success.
thank you very much!!
|
|
|
|
|
|
I have coded an expanding(growing)Array Class. After certain number of entries (Approximately 7 enters), I am unable to delete the Class. I get Debug Assertion Failed (_BLOCK_TYPE_IS_VALID).
I hope someone can help me...
|
|
|
|
|
Maybe if you post some source code...
Multiply it by infinity and take it beyond eternity and you'll still have no idea about what I'm talking about.
|
|
|
|
|
I have an icon in the system tray for my app to keep it running without showing in the taskbar. However, for whatever reason, my explorer (explorer.exe) crashes every once in a while, then refreshes. When it does this, the icon for my app is gone from the system tray, but others like SQL Server and various other apps I have running refresh themselves. Does anyone know how they do this, or better yet, how I can?
[insert witty comment here]
bdiamond
|
|
|
|
|
See this MSDN page on the taskbar[^] and search for "TaskbarCreated". That section tells you what do to (basically you just handle a registered message and re-add your tray icon).
--Mike--
Personal stuff:: Ericahist | Homepage
Shareware stuff:: 1ClickPicGrabber | RightClick-Encrypt
CP stuff:: CP SearchBar v2.0.2 | C++ Forum FAQ
----
Windows troubleshooting: Reboot first, ask questions later.
Four fonts walk into a bar. The bartender says "Hey - get out! We don't want your type in here."
Pinky, are you pondering what I'm pondering?
I think so Brain, but if we shaved our heads, we'd look like weasels!
|
|
|
|
|
Hi there,
I'm having trouble upgrading my VC++ 6.0 to a .NET compiler (manually of course). I recently installed the free Visual C++ .NET 2003 toolkit from the Microsoft Web-site (they don't provide tech support for the toolkit). It's a command-line C++.NET compiler. I'm trying to integrate it into the VC++ 6.0. How do I do this?
Thanks
void()
|
|
|
|
|
Specify the directory in the the options, directory page under Executables. Make sure the path to the new compiler is above the path to the old one.
Note that the VC++6 debugger does not support the debug information generated by the new compiler, so you won't be able to use the integrated debugger to debug programs compiled with the new compiler.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
Hi, all,
I built a C++ dll which contains functions accessing database using OLEDB. I try to load the dll functions from Access VBA. I can successfully execute non-db functions in the dll. I can also successfully execute open/close connections to db functions. But I have troubles to open a recordset with a sql statement after open the connection to db. Everytime it gives several error messages saying "The instruction at xxxx referenced memory at xxxx. The memory could not be read". Does anyone has any idea what may cause this? Or does anyone has a successful example?
Thanks!
|
|
|
|
|
Hello,
I just finished a project of mine. Since I like the result, I would like to build the functionality into Visual Studio 6.0.
I searched the internet (codeproject, codeguru, msdn and google), but I found no relevant information.
If somebody might know an article, sdk or an other resource where I could find the information needed to build a com add-in, please link me to that information.
Thanks in advance.
|
|
|
|
|
Hi !
Does everyone know any good articles about how brute force works and how to realize it in C++ ?
MFG
RedDragon
Unix and C are the ultimate computer viruses.
Visit me: www.programming.info.ms
|
|
|
|
|
for (int i=0;i < maxKeySize;i++)
{
KeyType key(i);
if (Decrypt(data, key) == something_that_looks_like_plaintext)
{
all done.
break;
}
}
Software | Cleek
|
|
|
|
|
I want to create my own function like the Win32 API's, where you can use things like this: WS_VISBLE | WS_BORDER.
What opperator do I use to check for each style? and what variable type should I use? I'm guessing LONG or WORD
Winuser.h makes everything this way: #define SOMETHING 0x10000000L.
So if I want 14 Flags, what should I make each one?
while I'm asking about opperators, here is some code that always executes no matter what style (it seems)
LONG Style = 0;
if((Style = GetWindowLong(hwnd,GWL_STYLE)) != 0){
if(!(Style & BS_TEXT)) {
SetWindowLong(hwnd,GWL_STYLE,Style & ~BS_BITMAP); if((Style = GetWindowLong(hwnd,GWL_STYLE)) != 0) SetWindowLong(hwnd,GWL_STYLE,Style | BS_TEXT); }
}
wWw.KruncherInc.cOm
|
|
|
|
|
Um haha, how do I get my code to format right?
wWw.KruncherInc.cOm
|
|
|
|
|
KingKruncher wrote:
What opperator do I use to check for each style?
and: &
1. set up your flags so they each take only one bit:
<br />
#define BIT_ZERO_FLAG (1 << 0)<br />
#define BIT_ONE_FLAG (1 << 1)<br />
#define BIT_TWO_FLAG (1 << 2)<br />
2. to test a flag:
<br />
if ((flag & BIT_ONE_FLAG) == BIT_ONE_FLAG)<br />
{<br />
.. bit one was set ..<br />
}<br />
or, if you don't want to define constants:
<br />
#define IsBitSet(_data,_bitpos) (((_data) & (1 << _bitpos))==(1 << _bitpos))<br />
<br />
bool bBit5IsSet = IsBitSet(flags, 5);<br />
Software | Cleek
|
|
|
|
|
Why would you define such macros?
If you want to test for a flag wheter it is set or not, a simple & is enough.
<br />
#define FLAG1 0x0001<br />
#define FLAG2 0x0002<br />
#define FLAGn n<br />
<br />
if( flags & FLAG1 )<br />
{<br />
}<br />
<br />
if( (flags & FLAG2) == FLAG2 )<br />
This way, you'll save some CPU cycles and you can define more flags
|
|
|
|
|
Bob Stanneveld wrote:
Why would you define such macros?
because you might be looking at individual bits for purposes other than testing pre-defined flags. and, it helps reduce errors like this:
if (data & BIT_POSITION_VALUE == BIT_POSITION_VALUE)
{
...
}
if ((data & BIT_POSITION_VALUE) == BIT_POSITION_VALUE)
{
...
}
Bob Stanneveld wrote:
This way, you'll save some CPU cycles and you can define more flags
there's no CPU savings there (except perhaps a micro-second worth of compiler time), because the pre-processor will turn that macro into code identical to what you show.
Software | Cleek
|
|
|
|
|
http://www.codeproject.com/cpp/bitbashing.asp[^]
"You're obviously a superstar." - Christian Graus about me - 12 Feb '03
"Obviously ??? You're definitely a superstar!!!" mYkel - 21 Jun '04
Within you lies the power for good - Use it!
|
|
|
|
|
Hi guys,
I developed SDI project, but I'm hiding the form view and showing only dialogs, these dialogs dont have a taskbar icon, I dont know how to make it shows, can anyone help me please
|
|
|
|
|
Hello,
I've been learning MFC with 3 different books. I'm at the point where I understand most of the basics. So I'm trying to write an useful program using AppWizard (I get the concept behind the code). The problem is, the examples in my books only show really, really basic applications where there is only one screen to interact (like a calculator). I want my application to be able to show the user different interfaces depending on what state it is in. i.e., I want to show a screen for the user to enter info (like name, age, location, etc), and when the user clicks another button, I want to show a different screen (like a jpeg/bitmap/chart, etc)... I don't know how to implement that. I'm using SDI. I'm guessing I need to use MDI and show/hide screen accordingly? If that is the case, do I just call the showWindow function? Any advice, hints, and explanation is much appreciated!
Thanks
|
|
|
|
|
It sounds like you are wanting a tabbed dialog, or a CPropertySheet object.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
hello,
i want to make program ras api completely,
i mean, i'll make the dial up(DUN) and the response for the dial up
for the the dial up is not my problem.
the problem is how to handle incoming connection using ras api?
i want to call incoming connection dialog in the windows programmatically with visual C++ and i don't know.
i am using window 2000
please help me, if anyone knows to handle this.....
|
|
|
|
|
Does anyone know where I get a get a good animation of a spinning hour glass, or somthing that would look good while the user waits for some hardware communication to complete?
Joel Holdsworth
|
|
|
|
|