|
Thanks, DavidCrow buddy!
I have another question. How to change from base 10
to another base? The function strtol() you introduced
to me can only change from base 16 to base 10.
regards,
George
|
|
|
|
|
Have you tried itoa()?
int num = 1234;
char str[32];
itoa(num, str, 8);
|
|
|
|
|
Thanks, DavidCrow buddy!
George
|
|
|
|
|
Has anyone done this? I currently have both Visual Studio 6.0 and VS.NET installed and would like to use the latest help system in both environments.
The way things are set up right now, I get the annoying message "The MSDN collection does not exist. Please reinstall MSDN." when I press F1 in VS 6.0. Things however work as expected in VS.NET.
Anyone?
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
Hello,
I am currently programming an application which embeds the Internet Explorer to display HTML pages.
I want to provide the users buttons like 'Go Back' and 'Go Forward'. It is easy to make the Internet Explorer do this (member functions .GoBack() and .GoForward()), but an error messagebox pops up if I call GoBack and am on the start page (so there is no previous page).
Is it possible to supress these messageboxes
-or-
How can I check if a previous/next page is available?
-Dominik
_outp(0x64, 0xAD);
and
__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
|
|
|
|
|
IE notifies you when you can and can't go back/forward. Intercept the OnCommandStateChange event (DISPID_COMMANDSTATECHANGE):
void __stdcall CWebBrowserWindow::OnCommandStateChange(
long Command, VARIANT_BOOL Enable )
{
switch( Command )
{
case CSC_NAVIGATEFORWARD:
m_bCanGoForward = ( Enable == VARIANT_TRUE ) ? true : false;
break;
case CSC_NAVIGATEBACK:
m_bCanGoBack = ( Enable == VARIANT_TRUE ) ? true : false;
break;
default:
break;
}
}
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
Where shall I implement this function? In my main application? If in my main application, how do I tell IE to use this callback function?
Thanks for your help!
-Dominik
_outp(0x64, 0xAD);
and
__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
|
|
|
|
|
I can tell you exactly how to do this if you are using ATL/WTL but I haven't got the code available for an MFC implementation. Basically what you have to do is to register with the web browser control that you want to receive events from it and then intercept the messages you want. In MFC you would probably use the BEGIN_EVENTSINK_MAP macro just to give you a hint.
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
Unfortunately I am using MFC without ATL/WTL.
I will try the BEGIN_EVENTSINK_MAP macro.
Thank you very much for your help!
-Dominik
_outp(0x64, 0xAD);
and
__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
|
|
|
|
|
I am trying to incorporate GDI+ drawing functions in my APP. I have seen that when doing so the print preview is
reduced to a ridiculuous size, while the printing action
remains OK.
Is there a way to solve this problem ?
thanks
jac.
|
|
|
|
|
Hi.
I'm creating a simple server-client application.
The client should listen for commands from the server, eg the server sends a shutdown command to the client, and then the client will shutdown windows.
But i'm not certan how to shutdown windows? is there any functions or anything like that?
Also, I'm in need of a way to turn of the monitor when a certan command has been send from the server to the client, but i'm not sure what to look at.
Thanks for any help I could get;P.
|
|
|
|
|
You can exit windows with ExitWindowsEx()
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Hi !!
There is a AllocSysString member in CString class. I want to give the same functionality to the string represented by std::string. Is it possible ???
|
|
|
|
|
AllocSysString is used for BSTR's so
just off the top of my head...
#include <comdef.h>
class MyString {
public:
std::string& get() {
return m_str;
}
operator BSTR () {
_bstr_t tmp;
tmp = m_str.c_str();
return tmp.copy();
}
protected:
std::string m_str;
};
this is pretty crude, but may give you some ideas...
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
|
|
|
|
|
Thanks for your response. Can you please also tell me that how can i use the operator BSTR of your class. Example if i have string
std::string strName = "Jim";
BSTR bstrName;
Now please tell me how i use your class to copy my std::string in BSTR.
Thanks.
|
|
|
|
|
std::string strName = "Jim";
BSTR bstrName;
MyString s;
s.get() = strName;
bstrName = s;
Thats it. But before you go using it, you should definitely read up on C++ operator overloads and conversion operators. COnversion operators are what allow you to do what we did above in the line:
bstrName = s;
Basically the compiler sees you have a conversion operator for the type of the assignment (in our case a BSTR) and then calls it for you.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
|
|
|
|
|
Hi,
I have a Application which uses a user-defined Dll.This Dll has many String constants defined in DLL resource string table.My problem is that I want to use that StringConstants ID defined in Dll in the main application..
So any idea ....how to do it.
cheers,
Super
------------------------------------------
Too much of good is bad,mix some evil in it
|
|
|
|
|
The first parameter to LoadString() is the instance handle of the resource DLL. For example:
HINSTANCE hInstance;
TCHAR szBuffer[128];
hInstance = LoadLibrary(_T("MyResourceLib.dll"));
LoadString(hInstance, ID_MSG_SOMESTRING, szBuffer, sizeof(szBuffer));
|
|
|
|
|
Hi professionals!
Where can I download DirectX 8.1 debug symbols of Visual C++ 6(SP5)?
John Seo(seojt@kogsoft.com)
|
|
|
|
|
Is it possible to download the DDK for Windows 2000 (Driver Development Kit)
from somewhere?
Microsoft distributes it on CD.
I could not find a link for downloading.
Thank you in advance,
seval
|
|
|
|
|
|
Hello,
I use "CreatePopupMenu()" to display a menu with right mouse click on a button.
This is an "ownerdraw" menu, so I draw bitmaps and I write text into each line.
My problem is there are too many lines to display. So I would like to add a vertical scrollbar into the popup menu.
|
|
|
|
|
Hi, I need my CListView derived class to have its horizontal scroll bar always visible (sometimes, of course, disabled). I tried following code:
BOOL CFileView1::Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext)
{
__DWORD newStyle = dwStyle | WS_VSCROLL;
__return CWnd::Create(lpszClassName, lpszWindowName, newStyle, rect, pParentWnd, nID, pContext);
}
but with no effect...
Will somebody help me?
Standa.
|
|
|
|
|
Hi Standa,
DWORD newStyle = dwStyle | WS_VSCROLL | LBS_DISABLENOSCROLL;
return CWnd::Create(lpszClassName, lpszWindowName, newStyle, rect, pParentWnd, nID, pContext);
May help you.
Best of luck
KVRN Kiran Kumar.
|
|
|
|
|
CFileFind won't help you much there. You will have to look into clipboard formats, specially CF_HDROP. Check out this MSDN article[^] for example.
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|