|
Alan Balkany wrote: Visual Studio 2005, Version 8.0.50727.42.
Check. My project creates a .lib, I don't believe there is a setting to alter that. Look in your build log, it should be a .htm file and under the Output section you should see something like:
Compiling resources...
Linking...
Creating library C:\Projects\VS2005\CPP\Bartnet\Debug\Bartnet.lib and object C:\Projects\VS2005\CPP\Bartnet\Debug\Bartnet.exp
Embedding manifest...
led mike
|
|
|
|
|
OK, this is what I get at the end of the Output section:
Compiling manifest to resources...
Linking...
LINK : C:\Alan\4000\Test Architecture\CppDll\Debug\CppDll.dll not found or not built by the last incremental link; performing full link
Embedding manifest...
Performing Post-Build Event...
1 file(s) copied.
So it mentions the DLL but not a LIB. Any suggestions?
|
|
|
|
|
Alan Balkany wrote: Any suggestions?
Nothing good. My project is old but I don't believe I changed any settings, so perhaps if you create a new DLL project, build it, verify it generates a .lib file.
Then you can compare the settings in the new project to your original project settings and find the problem.
led mike
|
|
|
|
|
In MS C++ 6.0 version
1. open Project->Settings using menu or clicking Alt+F7
2. Select your DLL project from left menu
3. Goto Link tab
4. Select General from Category
5. There's an option Doesn't Produce .LIB if it's checked just uncheck it
|
|
|
|
|
Thanks for the suggestion, but I've got version 8, which doesn't have the option you mentioned in step 5.
|
|
|
|
|
DLL Project settings/Linker/Advanced/Import Library
What's the setting there?
Also check the linker commandline - there should be a /IMPLIB: command line
switch there somewhere - if not, then the above project setting is not set.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Import Library: $(TargetDir)$(TargetName).lib
|
|
|
|
|
I would expect the lib file to be alongside the dll file.
Also this from the docs:
"If no exports are specified, LINK does not create an import library.
If an export file is used in the build, LINK assumes that an import
library already exists and does not create one."
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I have an activex component that is loaded whenever we load a page . The activex takes input data from the web page and after processing it returns the reply by firing an event .It works fine for a single tab but when I open the same page (from a webserver) in two or more tabs the events defined in the activex are not able to send the data to the correct tab .Sometimes it is send to the first tab.
How can I send the reply to the correct tab of IE
Thanks
|
|
|
|
|
Shailendra Sason wrote: it returns the reply by firing an event
Post the relevant code?
led mike
|
|
|
|
|
hi all
plz help me to find a good book for Mobile phone Programming .
@ i want to know about programming structures of mobile phones ....
but i doesnot need where to start from ...plz help me & guide step by step..
plz tell which programming languages , softwares are needed for this.
i have knowledge of some basic programming languages c#,c++ , but not masters in it... so plz masters tell me from where to start ... .
what is the best way to start this to step by step.
thanks very lot for any help !
Regards
s_mostafa_h
|
|
|
|
|
I went to my phone mfg's Web site. They had a whole section on (Java) programming for it.
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I suggest you to learn Java
keywords:
Java, Java mobility pack, Eclipse, Net Beans
|
|
|
|
|
thanks a lot for ur reply !
what things we can do with Java ? some friends talk about the power of c++ . what's i search about this is for e.g. making a simple application can remove the Password of cell phone when a user forgot it for Some Symbian OS or ...?
thanx a lot !
s_mostafa_h
|
|
|
|
|
I ran into some problems with COleDateTime.ParseDateTime that I didn't understand, so I assumed that my app was misusing/abusing them. I tried instead to write a small cmd-line app with MFC support that would explain the problem... here is the src code:
<br />
#include "stdafx.h"<br />
#include "TestDateTime3.h"<br />
<br />
#ifdef _DEBUG<br />
#define new DEBUG_NEW<br />
#undef THIS_FILE<br />
static char THIS_FILE[] = __FILE__;<br />
#endif<br />
<br />
<br />
CWinApp theApp;<br />
<br />
using namespace std;<br />
<br />
int _tmain(int argc, TCHAR* argv[], TCHAR* envp[])<br />
{<br />
int nRetCode = 0;<br />
<br />
if (!AfxWinInit(::GetModuleHandle(NULL), NULL, ::GetCommandLine(), 0))<br />
{<br />
cerr << _T("Fatal Error: MFC initialization failed") << endl;<br />
nRetCode = 1;<br />
}<br />
else<br />
{<br />
COleDateTime *pTime = new COleDateTime();<br />
pTime->ParseDateTime(_T("1/25/1996 8:30:00"));<br />
}<br />
<br />
return nRetCode;<br />
}<br />
The interesting part is:
<br />
COleDateTime *pTime = new COleDateTime();<br />
pTime->ParseDateTime(_T("1/25/1996 8:30:00"));<br />
This always returns failure and sets the status flag to invalid. I can also try formats such as "2001/01/01" or "1/1/2007" all to the same effect.
If I run it under the debugger, and try to step into ParseDateTime, it steps into COleCurrency::ParseCurrency instead of the intended method. I do not have any idea how or why that could possibly happen.
This is on a windows 2003 server machine. Are there any ideas out there?
|
|
|
|
|
Deeper into Pandora's box, I find that running in release mode it parses correctly, but debug builds fail. I still don't understand what could trigger the difference?
|
|
|
|
|
I don't know what to say, this works in both debug and release
COleDateTime dt;
dt.ParseDateTime(_T("1/25/1996 8:30:00"));
((CStatic*)CDialog::GetDlgItem(IDC_DATETIME))->SetWindowText(dt.Format());
led mike
|
|
|
|
|
You should check the international settings for when you test this. If the date setting is 'DD/MM/YYYY', that could be causing your difficulty.
Chris Meech
I am Canadian. [heard in a local bar]
In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]
Donate to help Conquer Cancer[ ^]
|
|
|
|
|
It is an interesting guess, but my settings are US, and hardcoding the lcid to US English doesn't help either. I never did figure it out, but I guess its not too big of a problem since the release builds work.
|
|
|
|
|
I am having a dialog box application (main dialog box in which many other child dialog boxes are created) in which I am having a closed loop function which does a series of other functions(doing some computations and updating some dialog boxes) continuously untill the user stops. For this we are using TIMERs, but using TIMERs I see there is atleast 10ms delay between the end of first TIMER to the start of next TIMER. We are trying to improve our closed loop frequency and I am not able to reduce this delay?? Is there any other better way rather than using TIMERs, like using threads (but the problem is when I tried using threads before, the interface doesnt respond anymore once the thread has started).
thanks in advance.
PKNT
|
|
|
|
|
Kiran Satish wrote: like using threads (but the problem is when I tried using threads before, the interface doesnt respond anymore once the thread has started)
That means you need to properly using threads.
How are you using timers? How did you use threads?
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
|
|
|
|
|
Yes... I know I haven't used threads in proper way in this particular application .
Well I used them in more sumple way, once the user clicks on 'Close Loop' button on one of the dialog boxes, I start a thread that does all the necessary work, but I remember it giving errors when I send/post messages to dialog boxes (but I am not sure) and the interface doesnt respnd anymore to user inputs.
Coming to TIMERs, here is how we are using currently-
<br />
void CAnalysisDlg::OnCloseloop() <br />
{<br />
CButton *ClButton;<br />
HICON icn;<br />
ClButton = (CButton *)GetDlgItem(IDB_CLOSELOOP);<br />
icn = ClButton->GetIcon();<br />
if(icn == AfxGetApp()->LoadIcon(IDI_CLOSELOOP))<br />
{<br />
ClButton->SendMessage(BM_SETIMAGE,IMAGE_ICON,(LPARAM)AfxGetApp()->LoadIcon(IDI_LOOPCLOSED));<br />
if(parent->closeLoop() == FALSE)<br />
{<br />
ClButton->SendMessage(BM_SETIMAGE,IMAGE_ICON,(LPARAM)AfxGetApp()->LoadIcon(IDI_CLOSELOOP));<br />
}<br />
}<br />
else<br />
{<br />
KillTimer(1);<br />
parent->Uncheck_Closeloop();<br />
}<br />
}<br />
BOOL CMainDlg::closeLoop()<br />
{<br />
if(OnAutoMeasure()==FALSE)<br />
return FALSE;<br />
}<br />
<br />
BOOL CMainDlg::OnAutoMeasure()<br />
{<br />
SetTimer(1,1,NULL);<br />
return TRUE;<br />
}<br />
<br />
void CMainDlg::OnTimer(UINT nIDEvent) <br />
{<br />
CButton *ClButton;<br />
HICON icn;<br />
KillTimer(1);<br />
ClButton = (CButton *)tbdisp->GetDlgItem(IDB_CLOSELOOP);<br />
icn = ClButton->GetIcon();<br />
if(icn == AfxGetApp()->LoadIcon(IDI_LOOPCLOSED))<br />
{<br />
if(closeloopsafety <= NUM_FALSE_RETURN_AUTOMEASURE)<br />
{<br />
if(OnAutoMeasure()==FALSE)<br />
Uncheck_Closeloop();<br />
}<br />
else<br />
Uncheck_Closeloop();<br />
}<br />
CDialog::OnTimer(nIDEvent);<br />
}<br />
I hope the code wont be too much of confusion . But that how its basically works now.
PKNT
|
|
|
|
|
this is NOT because of the MFC's Timer (which is in fact a wrapper to Win32), but because Windows is NOT a Real Time OS...
so you cannot expect much efficiency from there.
|
|
|
|
|
Yes.. its true. But I never had much of problems using threads in MFC, they used to work better. But well you can't compare it with other real-time OSes like Linux and other packages that you can get that makes Windows as real-time OS though .
PKNT
|
|
|
|
|
but maybe your processor is overloaded in kernel mode...
|
|
|
|