|
If the "standard" CxImage library does the job, and you have the source files (I suppose they are available) then you may have a look at.
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]
|
|
|
|
|
I even tried doing so just by changing the solution platform to "Pocket PC 2003(ARM)" but i am ending up with
error LNK2019: unresolved external symbol "public: bool __thiscall CxImage::Load(char const *,unsigned long)" (?Load@CxImage@@QAE_NPBDK@Z) referenced in function "protected: virtual int __thiscall CMyImageDlg::OnInitDialog(void)" (?OnInitDialog@CMyImageDlg@@MAEHXZ)
error LNK2019: unresolved external symbol "public: __thiscall CxImage::CxImage(unsigned long)" (??0CxImage@@QAE@K@Z) referenced in function "protected: virtual int __thiscall CMyImageDlg::OnInitDialog(void)" (?OnInitDialog@CMyImageDlg@@MAEHXZ)
My project setting are "Statically linked to MFC" "Using unicode"
Thanks!
|
|
|
|
|
Well, of course changing just the solution platform don't do the trick. You have to port some (i.e. the missing) code from the standard library to the WINCE one.
You've to put some effort in it, but it may be quite instructive, I suppose.
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]
|
|
|
|
|
Have you tried changing the
#define CXIMAGE_SUPPORT_JP2 0
to
#define CXIMAGE_SUPPORT_JP2 1
and re-building it to see what falls out?
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
After making that change only i have come across the errors that i have mentiontioned in the previous message!
|
|
|
|
|
Which errors? There were no errors mentioned in the message I responded to.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
i am ending up with
error LNK2019: unresolved external symbol "public: bool __thiscall CxImage::Load(char const *,unsigned long)" (?Load@CxImage@@QAE_NPBDK@Z) referenced in function "protected: virtual int __thiscall CMyImageDlg::OnInitDialog(void)" (?OnInitDialog@CMyImageDlg@@MAEHXZ)
error LNK2019: unresolved external symbol "public: __thiscall CxImage::CxImage(unsigned long)" (??0CxImage@@QAE@K@Z) referenced in function "protected: virtual int __thiscall CMyImageDlg::OnInitDialog(void)" (?OnInitDialog@CMyImageDlg@@MAEHXZ)
The latest observation is if i am changing some setting in Code generation to [/Mt] [/Mtd] [/Md] etc I get lot of such type of errors !
now after rolling back the settings also still the errors continues i am posting some of the errors
Linking...
LINK : warning LNK4199: /DELAYLOAD:OleAcc.dll ignored; no imports found from OleAcc.dll
MyImage.obj : error LNK2001: unresolved external symbol __afxForceEXCLUDE
ImageDlg.obj : error LNK2001: unresolved external symbol __afxForceEXCLUDE
stdafx.obj : error LNK2001: unresolved external symbol __afxForceEXCLUDE
MyImage.obj : error LNK2001: unresolved external symbol "protected: static struct AFX_MSGMAP const * __stdcall CWinApp::GetThisMessageMap(void)" (?GetThisMessageMap@CWinApp@@KGPBUAFX_MSGMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "protected: void __thiscall CWinApp::OnHelp(void)" (?OnHelp@CWinApp@@IAEXXZ)
MyImage.obj : error LNK2019: unresolved external symbol "public: __thiscall CWinApp::CWinApp(char const *)" (??0CWinApp@@QAE@PBD@Z) referenced in function "public: __thiscall CMyImageApp::CMyImageApp(void)" (??0CMyImageApp@@QAE@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual struct CRuntimeClass * __thiscall CWinApp::GetRuntimeClass(void)const " (?GetRuntimeClass@CWinApp@@UBEPAUCRuntimeClass@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CObject::Serialize(class CArchive &)" (?Serialize@CObject@@UAEXAAVCArchive@@@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CObject::Serialize(class CArchive &)" (?Serialize@CObject@@UAEXAAVCArchive@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::AssertValid(void)const " (?AssertValid@CWinApp@@UBEXXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::Dump(class CDumpContext &)const " (?Dump@CWinApp@@UBEXAAVCDumpContext@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::OnCmdMsg(unsigned int,int,void *,struct AFX_CMDHANDLERINFO *)" (?OnCmdMsg@CCmdTarget@@UAEHIHPAXPAUAFX_CMDHANDLERINFO@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CCmdTarget::OnFinalRelease(void)" (?OnFinalRelease@CCmdTarget@@UAEXXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::IsInvokeAllowed(long)" (?IsInvokeAllowed@CCmdTarget@@UAEHJ@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::IsInvokeAllowed(long)" (?IsInvokeAllowed@CCmdTarget@@UAEHJ@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::GetDispatchIID(struct _GUID *)" (?GetDispatchIID@CCmdTarget@@UAEHPAU_GUID@@@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::GetDispatchIID(struct _GUID *)" (?GetDispatchIID@CCmdTarget@@UAEHPAU_GUID@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual unsigned int __thiscall CCmdTarget::GetTypeInfoCount(void)" (?GetTypeInfoCount@CCmdTarget@@UAEIXZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual unsigned int __thiscall CCmdTarget::GetTypeInfoCount(void)" (?GetTypeInfoCount@CCmdTarget@@UAEIXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual class CTypeLibCache * __thiscall CCmdTarget::GetTypeLibCache(void)" (?GetTypeLibCache@CCmdTarget@@UAEPAVCTypeLibCache@@XZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual class CTypeLibCache * __thiscall CCmdTarget::GetTypeLibCache(void)" (?GetTypeLibCache@CCmdTarget@@UAEPAVCTypeLibCache@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual long __thiscall CCmdTarget::GetTypeLib(unsigned long,struct ITypeLib * *)" (?GetTypeLib@CCmdTarget@@UAEJKPAPAUITypeLib@@@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual long __thiscall CCmdTarget::GetTypeLib(unsigned long,struct ITypeLib * *)" (?GetTypeLib@CCmdTarget@@UAEJKPAPAUITypeLib@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_OLECMDMAP const * __thiscall CCmdTarget::GetCommandMap(void)const " (?GetCommandMap@CCmdTarget@@MBEPBUAFX_OLECMDMAP@@XZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_OLECMDMAP const * __thiscall CCmdTarget::GetCommandMap(void)const " (?GetCommandMap@CCmdTarget@@MBEPBUAFX_OLECMDMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_DISPMAP const * __thiscall CCmdTarget::GetDispatchMap(void)const " (?GetDispatchMap@CCmdTarget@@MBEPBUAFX_DISPMAP@@XZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_DISPMAP const * __thiscall CCmdTarget::GetDispatchMap(void)const " (?GetDispatchMap@CCmdTarget@@MBEPBUAFX_DISPMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_CONNECTIONMAP const * __thiscall CCmdTarget::GetConnectionMap(void)const " (?GetConnectionMap@CCmdTarget@@MBEPBUAFX_CONNECTIONMAP@@XZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_CONNECTIONMAP const * __thiscall CCmdTarget::GetConnectionMap(void)const " (?GetConnectionMap@CCmdTarget@@MBEPBUAFX_CONNECTIONMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_INTERFACEMAP const * __thiscall CCmdTarget::GetInterfaceMap(void)const " (?GetInterfaceMap@CCmdTarget@@MBEPBUAFX_INTERFACEMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_EVENTSINKMAP const * __thiscall CCmdTarget::GetEventSinkMap(void)const " (?GetEventSinkMap@CCmdTarget@@MBEPBUAFX_EVENTSINKMAP@@XZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_EVENTSINKMAP const * __thiscall CCmdTarget::GetEventSinkMap(void)const " (?GetEventSinkMap@CCmdTarget@@MBEPBUAFX_EVENTSINKMAP@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::OnCreateAggregates(void)" (?OnCreateAggregates@CCmdTarget@@UAEHXZ)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CCmdTarget::OnCreateAggregates(void)" (?OnCreateAggregates@CCmdTarget@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual struct IUnknown * __thiscall CCmdTarget::GetInterfaceHook(void const *)" (?GetInterfaceHook@CCmdTarget@@UAEPAUIUnknown@@PBX@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "public: virtual struct IUnknown * __thiscall CCmdTarget::GetInterfaceHook(void const *)" (?GetInterfaceHook@CCmdTarget@@UAEPAUIUnknown@@PBX@Z)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual int __thiscall CCmdTarget::GetExtraConnectionPoints(class CPtrArray *)" (?GetExtraConnectionPoints@CCmdTarget@@MAEHPAVCPtrArray@@@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual int __thiscall CCmdTarget::GetExtraConnectionPoints(class CPtrArray *)" (?GetExtraConnectionPoints@CCmdTarget@@MAEHPAVCPtrArray@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "protected: virtual struct IConnectionPoint * __thiscall CCmdTarget::GetConnectionHook(struct _GUID const &)" (?GetConnectionHook@CCmdTarget@@MAEPAUIConnectionPoint@@ABU_GUID@@@Z)
MyImageDlg.obj : error LNK2001: unresolved external symbol "protected: virtual struct IConnectionPoint * __thiscall CCmdTarget::GetConnectionHook(struct _GUID const &)" (?GetConnectionHook@CCmdTarget@@MAEPAUIConnectionPoint@@ABU_GUID@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::Run(void)" (?Run@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinThread::PreTranslateMessage(struct tagMSG *)" (?PreTranslateMessage@CWinThread@@UAEHPAUtagMSG@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinThread::PumpMessage(void)" (?PumpMessage@CWinThread@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::OnIdle(long)" (?OnIdle@CWinApp@@UAEHJ@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinThread::IsIdleMessage(struct tagMSG *)" (?IsIdleMessage@CWinThread@@UAEHPAUtagMSG@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::ExitInstance(void)" (?ExitInstance@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual long __thiscall CWinApp::ProcessWndProcException(class CException *,struct tagMSG const *)" (?ProcessWndProcException@CWinApp@@UAEJPAVCException@@PBUtagMSG@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinThread::ProcessMessageFilter(int,struct tagMSG *)" (?ProcessMessageFilter@CWinThread@@UAEHHPAUtagMSG@@@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual class CWnd * __thiscall CWinThread::GetMainWnd(void)" (?GetMainWnd@CWinThread@@UAEPAVCWnd@@XZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinThread::Delete(void)" (?Delete@CWinThread@@UAEXXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::InitLibId(void)" (?InitLibId@CWinApp@@UAEXXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::Register(void)" (?Register@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::Unregister(void)" (?Unregister@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual class CDocument * __thiscall CWinApp::OpenDocumentFile(char const *)" (?OpenDocumentFile@CWinApp@@UAEPAVCDocument@@PBD@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::AddToRecentFileList(char const *)" (?AddToRecentFileList@CWinApp@@UAEXPBD@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::InitApplication(void)" (?InitApplication@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::SaveAllModified(void)" (?SaveAllModified@CWinApp@@UAEHXZ)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::DoMessageBox(char const *,unsigned int,unsigned int)" (?DoMessageBox@CWinApp@@UAEHPBDII@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::DoWaitCursor(int)" (?DoWaitCursor@CWinApp@@UAEXH@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CWinApp::OnDDECommand(char *)" (?OnDDECommand@CWinApp@@UAEHPAD@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::WinHelpA(unsigned long,unsigned int)" (?WinHelpA@CWinApp@@UAEXKI@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::HtmlHelpA(unsigned long,unsigned int)" (?HtmlHelpA@CWinApp@@UAEXKI@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall CWinApp::WinHelpInternal(unsigned long,unsigned int)" (?WinHelpInternal@CWinApp@@UAEXKI@Z)
MyImage.obj : error LNK2001: unresolved external symbol "public: virtual struct HINSTANCE__ * __thiscall CWinApp::LoadAppLangResourceDLL(void)" (?LoadAppLangResourceDLL@CWinApp@@UAEPAUHINSTANCE__@@XZ)
and so on ..... (228 errors)
|
|
|
|
|
Your first two linker errors would appear to be because you aren't linking to the CxImage libraries.
The other areas are because you're not linking against MFC libraries.
It's not difficult - look at the missing symbol names, work out which libraries they come from, add those libraries to the list of 'Additional Dependencies' on the Linker->Input settings.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Hello,
I have a CRichEditCtrl box on a CMDIChildWnd which is created and displayed properly on the window.
But when the window loses focus and if the focus is brought back to the window then the focus mouse cursor doesnt appear on the window. The mouse cannot be clicked on the CRichEditCtrl window or if clicked the editing mouse cursor doesnt appear on the CRichEditCtrl window. The CrichEditCTrl window appears as if dead on the CMDIChildWnd where the text is visible but cannot be edited or clicked .
What must be the reason?
Prithaa
|
|
|
|
|
I have tried implementing isenslogon but i am not able to get notification.
I have out logs in the function implementation for logon/logoffas follows
interface MyISensLogon : public ISensLogon
{
private:
long ref;
HWND IsensLog;
public:
MyISensLogon()
{
ref = 1;
}
STDMETHODIMP QueryInterface(REFIID iid, void ** ppv)
{
if (IsEqualIID(iid, IID_IUnknown) || IsEqualIID(iid, IID_IDispatch) ||IsEqualIID(iid, __uuidof(ISensLogon)))
{
*ppv = this;
AddRef();
return S_OK;
}
*ppv = NULL;
return E_NOINTERFACE;
}
ULONG STDMETHODCALLTYPE AddRef ()
{
return InterlockedIncrement(&ref);
}
ULONG STDMETHODCALLTYPE Release ()
{
int tmp;
tmp = InterlockedDecrement(&ref);
return tmp;
}
HRESULT STDMETHODCALLTYPE GetTypeInfoCount(/* [out] */ UINT *pctinfo )
{
return E_NOTIMPL;
}
HRESULT STDMETHODCALLTYPE GetTypeInfo ( UINT iTInfo, LCID lcid,ITypeInfo **ppTInfo)
{
return E_NOTIMPL;
}
HRESULT STDMETHODCALLTYPE GetIDsOfNames (REFIID riid, LPOLESTR *rgszNames,UINT cNames, LCID lcid,DISPID *rgDispId)
{
return E_NOTIMPL;
}
HRESULT STDMETHODCALLTYPE Invoke (DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags, DISPPARAMS *pDispParams,VARIANT *pVarResult, EXCEPINFO *pExcepInfo,UINT *puArgErr)
{
return E_NOTIMPL;
}
virtual HRESULT STDMETHODCALLTYPE Logon(BSTR bstrUserName)
{
WriteLog( "Ctrl-LogON event\n\n" );
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE Logoff(BSTR bstrUserName)
{
sprintf(temp,"Logoff for user %s with CurrentSID = %s",user,CurrentSID);
WriteLog(temp);
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE StartShell( BSTR bstrUserName)
{
WriteLog("Inside StartShell");
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE DisplayLock( BSTR bstrUserName)
{
WriteLog("Inside DisplayLock");
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE DisplayUnlock( BSTR bstrUserName)
{
WriteLog("Inside DisplayUnlock");
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE StartScreenSaver( BSTR bstrUserName)
{
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE StopScreenSaver( BSTR bstrUserName)
{
return S_OK;
}
};
subscription func is follows :-
static MyISensLogon *pISensLogon = 0;
HRESULT SubscribeLogoffNotification()
{
IEventSubscription* pIEventSubscription = 0;
HRESULT hr = S_OK;
HRESULT comInit = E_FAIL;
HRESULT res = S_OK;
WCHAR buffer[64] = {0};
int i = 0;
comInit = CoInitialize(0);
if (comInit != RPC_E_CHANGED_MODE)
{
hr = comInit;
if (FAILED(hr))
{
goto error;
}
}
res=CoCreateInstance(__uuidof(CEventSystem), 0,CLSCTX_SERVER,__uuidof(IEventSystem),(void**)&pIEventSystem);
if((FAILED(res))|| (NULL == pIEventSystem))
{
WriteLog("SubscribeLogoffNotification : Error create com instance for CEventSystem");
goto error;
}
pISensLogon= new MyISensLogon();
char temp[220];
for(i=0; i<7; i++)
{
sprintf(temp,"\nSubscribeLogoffNotification for i=%d started",i);
WriteLog(temp);
res=CoCreateInstance(__uuidof(CEventSubscription),0, CLSCTX_SERVER,__uuidof(IEventSubscription),(LPVOID*)&pIEventSubscription);
if((FAILED(res))
|| (NULL == pIEventSubscription))
{
goto error;
WriteLog("\nSubscribeLogoffNotification : Error create com instance for CEventSubscription");
}
res=pIEventSubscription->put_EventClassID(OLESTR("{d5978630-5b9f-11d1-8dd2-00aa004abd5e}"));
if(FAILED(res))
goto error;
res=pIEventSubscription->put_SubscriberInterface((IUnknown*)pISensLogon);
if(FAILED(res))
goto error;
MultiByteToWideChar(0,0,methods[i],-1,buffer,64);
res=pIEventSubscription->put_MethodName(buffer);
if(FAILED(res))
goto error;
MultiByteToWideChar(0,0,names[i],-1,buffer,64);
res=pIEventSubscription->put_SubscriptionName(buffer);;
if(FAILED(res))
goto error;
MultiByteToWideChar(0,0,subids[i],-1,buffer,64);
res=pIEventSubscription->put_SubscriptionID(buffer);
if(FAILED(res))
goto error;
res=pIEventSystem->Store(PROGID_EventSubscription,(IUnknown*)pIEventSubscription);
if(FAILED(res))
goto error;
pIEventSubscription->Release();
pIEventSubscription=0;
sprintf(temp,"\nSubscribeLogoffNotification for i=%d Completed",i);
WriteLog(temp);
}
res = S_OK;
return res;
error:
CoUninitialize();
return res;
}
with loads of thanks
|
|
|
|
|
Hi,
I am working in an application with docking window like Visual Studio 2005 interface. I do it with Visual Studio 2008 and MFC.
The left pane is a CTreeCtrl. I put items in it. When I click on an item, I want to display a form in the view portion of the application.
To do that, I have a member function called void CViewTree::OnTvnSelchanged(NMHDR *pNMHDR, LRESULT *pResult) to catch the event.
To display the form associated with the item clicked, I have to access the view class and after that the document class.
I access the view like that from the CViewTree::OnTvnSelchanged function:
CFrameWnd *pFrameWnd = (CFrameWnd*)AfxGetApp()->m_pMainWnd;
CCDSView* pView;
pView = (CCDSView*)pFrameWnd->GetActiveView();
I get memory leaks, but the program run anyway.
What I can't understand is that the program run under Vista 64 Home premium at home, but not run on an XP computer at office.
I compile it with Net Framework 2.0.
Does it has another way to access the view or document that does not crash my application ?
Thanks,
Claude
|
|
|
|
|
I am currently writing an application using C++ and MFC. I am in the process of trying to add a tool bar to my application. The class I am using to do this is CToolBarCtrl. The tool bar will have several buttons on it but all these buttons must be represented ( at least as I understand it )
by a single bitmap. I am finding it very difficult to create this bitmap and have it look good. I am using the bitmap editor that came with Visual Studio. Part of the problem is that I cannot get things
lined up right. Also, once a get a letter onto the bitmap, I do not seem to be able to move it. This
is often necessary since I do not always but it in the right place to start with.
I am wondering if I could create one bitmap for each button and then put all the bitmaps together to come up with one large bitmap.
I am hoping that somebody out there will have a suggestion for me.
Thanks
Bob
|
|
|
|
|
Of course it can be moved.
Mark the selection using the rectangle selection tool and drag it with the mouse.
«_Superman_»
I love work. It gives me something to do between weekends.
|
|
|
|
|
The built-in bitmap editor is pretty limited and hard to work with. Try downloading Gimp or Paint.net.
Both are free, and much better for this kind of work.
There are three kinds of people in the world - those who can count and those who can't...
|
|
|
|
|
Thanks for the responses. They were helpfully and I am now using GIMP. I believe it works better
than the Microsoft tool.
Bob
|
|
|
|
|
I was just wondering how to use the windows 7 sdk with qt?
thanks
|
|
|
|
|
Have you tried installing them both and...well, just using them?
It should just be a case of setting suitable include and library paths for the compiler toolchain, I would have thought?
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
|
|
|
Well, the example you point at is for VC6, not VS2008 (which I guess is what you mean - there's no VC++2009) - and ATL has changed quite a lot since VC6.
You might try this more up to date example[^].
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
You must be a mind reader!!
Yes, it's 2008 (I was in a hurry and saw v 9 in Help->About)
Thanks a lot!!
I will give that example a try!
|
|
|
|
|
Dang it!
I opened the *.sln, Visual Studio did the conversion.
When I click build it does so in <1 second and says:
1>------ Skipped Rebuild All: Project: ATLCon ------
1>
========== Rebuild All: 0 succeeded, 0 failed, 1 skipped ==========
No output files are created.
If I open any of the *.cpp files and attempt to compile them individually I get a popup message saying The operation could not be completed. Unspecified Error. ...
I tried the attribute and non-attribute versions.
One of the comments in the conversion log of the non-attributes version says "ATL Server support has been removed from this version of Visual Studio. In case your ATL Project uses any ATL Server functionality, your project may not build. Please consult the MSDN documentation for a list of alternatives." so... Is ATL going away or somthing...?
|
|
|
|
|
|
Bummer... the atlcon samples that come with vs 2008 msdn install don't work either
C:\Program Files\Microsoft Visual Studio 9.0\Samples\1033\AllVCLanguageSamples\C++\ATL\General\AtlCon
|
|
|
|
|