|
Again extract and save that file and change encoding (ANSI) to encoding (unicode).
Yes U Can ...If U Can ,Dream it , U can do it ...ICAN
|
|
|
|
|
Hi All!
I want to use some off the shelf ActiveX components in my project for visual display of information e.g. analog dials, thermometers, digital displays and graphs. I am using VC++ .NET 2005. Any body guide me in finding such ActiveX contols which are flexable but not too expensive, thanks.
<cool head="" makes="" lips="" smile="" more="">
|
|
|
|
|
There are some nice free controls on this website. Just search through the articles. But these are not ActiveX controls but just plain standard controls.
I developped also a charting control, check my sig if you are interested.
|
|
|
|
|
I have a CTreeCtrl in side a CDialog base class.
The hot keys are not functioning when the focus is on is on the Tree.
How to enable the hotkey function for CTreeCtrl??
Any suggestions??
Priya Sundar
|
|
|
|
|
Hi All,
I have created one simple application which inherits the CScrollBar Class of MFC.
problem is that when i run my application and click on ScrollBar nothing is happening.
no events are generated and sent to my class.
Can anyone tell me what could be the problem ? , did i miss anything ?
|
|
|
|
|
Your program didnt get any events or you forgot to declare these events on your program?
|
|
|
|
|
|
Hi,
I am using Visual Studio 2003 and trying to attach to a program that I have written in C++.
I am attempting to attach the debugger remotely (using tcp/ip) to a program which has asserted.
If I attach to the program before it asserts, there is not a problem and when the code asserts I get the usual break, continue options in a msg box. However what I need to do (don't ask why!) is attach to the program after it has asserted. If I do this however, The msg box appears on the remote system (the only option is "ok") and I don't get one on my PC. Therefore I don't get the option to break and cannot get to the piece of code that the assert occured in.
Anyone got any ideas if what I'm trying to do is possible. I know it sounds a bit weird, but I really need to be able to do this after the assert has occured.
Thanks in advance!
|
|
|
|
|
I find it a bit complicated. The debugger comes when the assertion is triggered. If you try to attach a debugger after, i don't see how can it be usefull at all.
Can you access the code there, where the assertion occurs?
Other thing would be copy there the dlls that are used to debug, then the messagebox should come with the retry and so on (but it is just a guess).
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
|
|
|
|
|
I'm posting about this for second time, since no one replayed on my previous message!
I'm offering my users to chose hot key, I placed CHotKeyCtrl box on my dialog so they can do so. But when they press Win key nothing happens! If they would press for instance ctrl key or shift key CHotKeyCtrl box accepts it!
Why is this, or how can I make it accepts Win key also?
Thanks!
-- modified at 7:13 Thursday 18th October, 2007
|
|
|
|
|
|
Thanks for replay, I've solved my problem another way!
I viewed that article, but CHotKeyCtrl box on it's dialog also couldn't get Win key!
|
|
|
|
|
I gald it solved.
|
|
|
|
|
I have a VC++ program which used to print some document...my program gives same printing quality for all printers except EPSON- ink jet printer.....is there any printer specific routine i need to write which will support for epson fonts .my understanding is fonts and their charecteristics are printer independent! still why i suppose to get hazy fonts in epson...the printer is good working with other word documents....
thanx in advance...
birajendu
CyberG India
Delhi
India
|
|
|
|
|
I saw an article I think(not sure) it was on the codeproject about set some setting for printers but I forgot its name if you search on the codeproject you can find it.
|
|
|
|
|
Mmm, I was thinking it at the beggining too. But after programming the printing part of my project... I don't believe it anymore.
I got sucess declaring the things like that:
pDC->SetMapMode (MM_LOMETRIC);
CDC dcGraphMem; dcGraphMem.CreateCompatibleDC (pDC);
CFont fontLabels; fontLabels.CreatePointFont (80, "MS Sans Serif", pDC);
CFont fontInfo; fontInfo.CreatePointFont (140, "MS Sans Serif", pDC);
double dLeftOffset = 200 - (pDC->GetDeviceCaps (PHYSICALOFFSETX) * 254.0) / pDC->GetDeviceCaps (LOGPIXELSX);
double dTopOffset = 200 - (pDC->GetDeviceCaps (PHYSICALOFFSETY) * 254.0) / pDC->GetDeviceCaps (LOGPIXELSY);
double dRightMargin = 2770 - (pDC->GetDeviceCaps (PHYSICALOFFSETX) * 254.0) / pDC->GetDeviceCaps (LOGPIXELSX);
double dBottomMargin = 1950 -(pDC->GetDeviceCaps (PHYSICALOFFSETY) * 254.0) / pDC->GetDeviceCaps (LOGPIXELSY);
pInfo->m_rectDraw.left += (int) dLeftOffset;
pInfo->m_rectDraw.top += (int) dTopOffset;
pInfo->m_rectDraw.right = (int) dRightMargin;
pInfo->m_rectDraw.bottom = (int) dBottomMargin;
And then using it like that:
pDC->SelectObject (&fontLabels);
pDC->SetBkMode (TRANSPARENT);
pDC->TextOut (pInfo->m_rectDraw.left, 50 - pInfo->m_rectDraw.bottom, pDoc->GetFileName());
Hope it helps
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
|
|
|
|
|
Hello and good day. I currently have a problem with LoadImage (i think) in my application.
The application reads a file, changes it into bitmap format, uses LoadImage to display a file,
then uses StretchBlt to resize/rotate it. The user selects the file to load and display. Now the
problem is, I tried to do a stress test for it and the LoadImage fails after around 100 tries of
loading a 2000x2000 bmp file. I checked the HBITMAP handler which receives the data from the LoadImage and it contains NULL at that time. I still am not sure if the LoadImage is really the problem, I think it may be all the memory allocations I made but I checked them again and again and they were certainly released when a new image is loaded. Can somebody please advise me and help me about this problem?
Thank you!
|
|
|
|
|
|
The code is actually too large to paste in here. I can only paste the function which displays has the LoadImage part.
<br />
void CDlg::DisplayImage()<br />
{<br />
gOtherClass.gDisplayPanelHandle = (HBITMAP)::LoadImage<br />
( <br />
0, <br />
gMapPath, <br />
IMAGE_BITMAP, <br />
gSourceSize.cx,<br />
gSourceSize.cy,<br />
LR_DEFAULTCOLOR | LR_LOADFROMFILE <br />
);<br />
<br />
if(gOtherClass.gDisplayPanelHandle == NULL)<br />
{<br />
AfxMessageBox("Error!\nUnable to load Map File");<br />
return;<br />
}<br />
<br />
gCDC.SelectObject(gOtherClass.gDisplayPanelHandle);<br />
<br />
gCDC.StretchBlt<br />
(<br />
0, <br />
0,<br />
gSourceSize.cx,<br />
gSourceSize.cy,<br />
&gCDC,<br />
0, <br />
gSourceSize.cy - 1,
gSourceSize.cx,<br />
-gSourceSize.cy,<br />
SRCCOPY<br />
);<br />
Invalidate(FALSE);<br />
}<br />
|
|
|
|
|
What is gOtherClass.gDisplayPanelHandle?
|
|
|
|
|
its a class which contains all the shared variables between other characters. I have noticed also that after around 100 times of loading a bitmap, the application's performance is starting to decline.
|
|
|
|
|
Llasus wrote: gOtherClass.gDisplayPanelHandle
Do you destroy the handle after every display?
|
|
|
|
|
yes. I made sure that it destroys the object before loading the next image.
|
|
|
|
|
When calling SelectObject , you need to store the Pointer to the old GdiObject you get from the call and re-SelectObject it after finishing work.
You are producing a so called GDI-Resource-Leak. In the ProcessExplorer, you cann swith on display of used GDI-Objects.
Though I speak with the tongues of men and of angels, and have not money, I am become as a sounding brass, or a tinkling cymbal. George Orwell, "Keep the Aspidistra Flying", Opening words
|
|
|
|
|
Thank you for the help. I will try this tomorrow. I have not encountered this GDI-Resource-Leak though. Sorry but could you please explain further what you mean by re-SelectObject after finishing the work and why I need it? Usually when loading the next image I just use the DeleteObject() to somehow release the object for next use.
|
|
|
|