|
thank you ,i have a struct for displaying ,,but the struct data updata dynamic,,i can not alloc memory as the image for dispalyed data,,because the data is too huge.
|
|
|
|
|
How to change background color of button on dialog box in mfc
Project Engineer
|
|
|
|
|
Start by searching for WM_CTLCOLORBTN .
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
Color Button[^].
Of one Essence is the human race
thus has Creation put the base
One Limb impacted is sufficient
For all Others to feel the Mace
(Saadi )
|
|
|
|
|
Hi,
How can i read the meta-data information of files using VC++. I mean the information we see when we change the folder view to details. eg:- Author of MS-Word document etc.
thanks,
J.
|
|
|
|
|
Voila[^]
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Hello all
I have a big problem after upgrading to IE8 . In our filetransfer module we are using wininet_connect(..) to establish connections via gSoap client . It has been working fine till we upgraded to IE8 with wininet.dll version 8.0 . The problem is that the wininet_callback is getting INTERNET_STATUS_CONNECTION_CLOSED message due to which gSoap client is disconnecting . This does not happen in IE6 and its wininet.dll version ...
Has anyone faced this problem ?
redindian
|
|
|
|
|
Why don't execution function
MessageBox(L"DIVIDE BY ZERO"); ?
The code is skipping.
#include "Excpt.h"
#include "Winnt.h"
#include "cmath"
float fResult; // Bennet, pg.136
//int x,y;
float x,y;
// x = 5;
// y = 0;
x = 5.0;
y = 0.0;
_try // __try
{
fResult = x/y;
}
//__except (GetExceptionCode() == EXCEPTION_FLT_DIVIDE_BY_ZERO)
_except (GetExceptionCode() == EXCEPTION_FLT_DIVIDE_BY_ZERO)
{
MessageBox(L"DIVIDE BY ZERO");
}
|
|
|
|
|
You need to turn on floating-point exceptions first...
Try #includeing <float.h> and add this bit of code before you do the divide...
_controlfp(0, MCW_EM);
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
modified on Thursday, August 27, 2009 10:48 AM
|
|
|
|
|
Hi all,
Can any body tell me how to disable restore on title bar click.
Thanks
|
|
|
|
|
I presume you mean restoring a window from a minimized state?
If so, then your main window needs to handle WM_SYSCOMMAND[^] and call the inherited WndProc EXCEPT when the wParam == SC_RESTORE.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Hi,
I need help in creating a waterfall display of my image data stored in a buffer. The image needs to be displayed scrolling down the screen as its being acquired from the camera.
I am using visual studio c++ windows forms.
Can someone please help me to figure out how to achieve this display?
Thanks in advance
|
|
|
|
|
su_marvel wrote: I am using visual studio c++ windows forms.
I have a tough time figuring out your query, but thankfully it doesn't belong here. You can post managed c++ queries here[^]
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
Hi,
Following is the code I am trying to do
<#import "C:\\Program Files\\BOSS\\SUPPORT\\RealDWG\\cf2407.dll" rename_namespace("CADFilter")
AcRx::AppRetCode acrxEntryPoint (AcRx::AppMsgCode Msg,
void* AppId)
{
// local variables
int cindex;
CADFilter::NW_IDocument *m_pIDocument;
CLSID clsid;
CoInitialize (NULL);
HRESULT hr = CLSIDFromProgID(LPCOLESTR("NW_Document"), &clsid );
hr = CoCreateInstance( clsid, NULL,CLSCTX_ALL , __uuidof(CADFilter::NW_IDocument) , (void**)&m_pIDocument );
if(SUCCEEDED(hr))
{
AfxMessageBox(_T("Hi"));
}
}>
But I am getting an " HRESULT hr as an "Invalid class string"
|
|
|
|
|
Don't cross-post. Look in the COM forum, where I answered this question.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
is NW_Document a valid ProgID? Have you checked it with, for instance, OleView Tool?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
NW_Document is the name of my co class which i saw in .tlh file.
By the way how to get to know that the ProgID is valid or not and if not then what is ProgID
|
|
|
|
|
From MSDN [^]:
ProgIDs present a human-readable version of the class identifier (CLSID) used to identify COM/ActiveX objects.
deadlyabbas wrote: By the way how to get to know that the ProgID is valid or not and if not then what is ProgID
OleView tool helps. You may also have a look at the registry.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
deadlyabbas wrote: But I am getting an " HRESULT hr as an "Invalid class string"
I believe ProdID is should be something like this :
LibrarayName.InterfaceName.Version adn for version independent
LibraryName.Interface
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
Hi!
I'm executing 3rd party software from Windows service with CreateProcess() on a random environment. Sometimes the 3rd party software or the environment is not stable and a runtime error is thrown, eg. R6034.
The error will cause a popup window to appear on the desktop of interactive user. The service is running on a dedicated account and it doesn't seem to have any access to WinSta0 desktops, but the popup is still drawn on WinSta0\Default.
What I'd like to do, is to handle the error on the process calling CreateProcess and prevent the popup window from appearing to interactive user. I'm currently able to detect the error and handle it, but I still have to close the popup manually.
Is there any method to
1) prevent the runtime error popup window from appearing?
or
2) force the popup window to "appear" on the invisible windowstation/desktop of the service? (where it could be signalled to close)
Thanks in advance!
|
|
|
|
|
What i understood from your query is that, 3rd party software is making error, when it is not having enough access.
Why don't you check the access information of process before calling the CreateProcess ?
Величие не Бога может быть недооценена.
modified on Thursday, August 27, 2009 4:20 AM
|
|
|
|
|
The process should have access to everything it needs, but the process may be faulty (eg. manifest errors), or the environment may lack something (DLLs etc.), which will cause the runtime error to appear.
The process can be almost anything, for example it may contain a rarely used DLL which causes the runtime error thrown once and then. In the largest cases there can be hundreds of megabytes of DLLs in separate runtime libraries, and a runtime library may be the one causing the runtime error.
It's not possible to check the validity or stability of the 3rd party software in advance, so the only option is to handle the error when it occurs.
But thank you for your quick answer!
|
|
|
|
|
3rd party softwares are not usually used by standard softwares, until you have the source code or you are confident about it.
Validity can checked directly only if you have the source code of 3rd party.
But yes you can check whether it is having stability whether all the dependent DLL are available in this system. PE file parsing is enough for checking the stability, just refer the article(Parse a PE (EXE, DLL, OCX Files ) and New Dependency Walker[^])).Just check whether the all the dependent DLL are available and they are stable.
But that is a complex solution, and i don't prefer that too.
That is what you can do. But i don't think you have any direct way to check the validity of the that 3rd party software.
Величие не Бога может быть недооценена.
|
|
|
|
|
Unfortunately that's not possible.
The 3rd party software can be for example a compiled MATLAB code which depends on Matlab Runtime Libraries. Let's say that one of the Matlab Runtime Library DLLs causes runtime error when used from service account, and it's ok as long as the DLL is not used. But if the MATLAB code uses a function call that causes the DLL to be loaded, the problem occurs.
|
|
|
|
|
Since you don't have the code to know when it is loading the runtime lib, there is not much left other than some nasty stuffs like API hooking., which is not done in any standard application.
Величие не Бога может быть недооценена.
|
|
|
|