|
I'm currently working on a programming project that requires the use of graphics. I'm using Dev-C++'s V.4 compiler and borland's graphical interface, whick makes use of a header file called <winbgim.h>. I am trying to interact between the graphics window and a seperate input/output screen. I'm using the input/output screen to get info from the user and the graphics window to display results in graphical format. My problem is this: within five seconds of program execution, the graphics window becomes inactive, but the program will continue to feed information through the input/output screen. When the program is finished execution and terminated, and the graphics screen will once again become active and will display the results of what was happening during program execution when it was inactive.
I'm looking for any function or command which will set the graphics windows active each time I want to display results to it (i'm going to have to switch back and forth from the graphics window and input/output module). If there is no such function or command, please give me some advice of what my alternatives are.
Deadline is soon, and I'm sweating. Any type of help will be well appreciated.
-------------------------------------
- Mike Ware
- "The Programmer's Domain"
- http://www1.brinkster.com/warenet
-------------------------------------
|
|
|
|
|
can anybody advice me how to wrap text in CEdit control, if "Multiline" style is selected.
|
|
|
|
|
|
dudic wrote:
can anybody advice me how to wrap text in CEdit control, if "Multiline" style is selected.
To force a new line use a \n, otherwise text wraps itself at the end of each line.
Neville Franks, Author of ED for Windows. www.getsoft.com
Make money with our new Affilate program
|
|
|
|
|
I have a dialog based app that runs fine on my development machine. Problem starts when I install the release exe on another machine. The main dialog window fails to create and returns -1 in DoModal(). Any help would be appreciated.
Thanks,
Sterling
srunion@evokesoft.com
|
|
|
|
|
|
Alpha windows problem, need help!
I had download the code from:
http://www.codeproject.com/gdi/pxalphablend.asp
I've put controls on the dummy dialog. I can press a button on the dialog, just can't see it. Can anyone direct me to some help on how to make any controls appear on this dialog?
My OS is Win2000
VC 6
|
|
|
|
|
I've created a CStatic control in my View window like this:-
CRect rect (m_rectGraph.left, m_rectGraph.bottom, m_xChar * 6, yChar);<br />
m_wndLevel1Static.Create(_T("???"), WS_CHILD|WS_VISIBLE|SS_LEFT, rect,this);<br />
Now I need to move it to another area in the View window. I've tried SetWindowPos and MoveWindow but I can't be using them right because either it will not compile or it aborts when I run it.
Am I using the wrong function, or can any one offer a quick example?
Thanks for any help,
Ali
|
|
|
|
|
MoveWindow should work fine.. Are you trying to move it before it gets created? Maybe post your move code..
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
Hi everybody, help me
Why the following code draws a black color instead a transparent color
hBitmap - handle of a bitmap
crTransparent - a transparent color
CSize sz(0, 0);
int nRetValue;
BITMAP csBitmapSize;
nRetValue = ::GetObject(hBitmap, sizeof(csBitmapSize), &csBitmapSize);
sz.cx = (DWORD)csBitmapSize.bmWidth;
sz.cy = (DWORD)csBitmapSize.bmHeight;
CImageList img;
img.Create(sz.cx, sz.cy, ILC_COLORDDB | ILC_MASK, 1, 1);
img.Add(CBitmap::FromHandle(hBitmap), crTransparent);
HICON hIcon = img.ExtractIcon(0);
pDC->DrawState(pt, sz, hIcon, DSS_NORMAL, (CBrush*)NULL);
Best regards,
Eugene Pustovoyt
|
|
|
|
|
Hello,
It looks good to me, the only thing I can think of is maybe crTransparent doesn't equal the color your trying to make transparent..
In MSDN it says the following:
int Add( CBitmap* pbmImage, COLORREF crMask );
pbmImage
Pointer to the bitmap containing the image or images. The number of images is inferred from the width of the bitmap.
crMask
Color used to generate the mask. Each pixel of this color in the given bitmap is changed to black and the corresponding bit in the mask is set to one.
I usually set crMask equal to "RGB(255,0,255)" and make sure every pixel that I want to show transparent is RGB(255,0,255) in color..
Hope this helps..
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
Hello,
This is kind of a strange question.. When you have an app open or minimized you can see the button on the taskbar associated with the application.. Is there any way to change the title of the button on the task bar with out changing the title of the application??
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
This PC Mag utility[^] (with source code) may help you get at the items in the task bar. You should be able to rename the item without changing the title of the corresponding main window.
/ravi
Let's put "civil" back in "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
One solution is SetWindowsText().
SetWindowText();
ModifyStyle(WS_CAPTION, WS_SYSMENU, SWP_FRAMECHANGED);
Kuphryn
|
|
|
|
|
Please if any one of you can tell me
Can I block any packet using winsock API?
If yes then How refer any helping material.
__________________
Knowledge is Power
|
|
|
|
|
depends what you expect under "block a packet".
|
|
|
|
|
summo wrote:
Can I block any packet using winsock API?
No.
|
|
|
|
|
I download the demo project from
http://www.codeproject.com/gdi/pxalphablend.asp?target=alpha
but control on alphablended dialog all disappear? what's worng?
|
|
|
|
|
Post a message on the board at the bottom of the article itself - that way the article author gets sent an e-mail, and may be able to help.
Dave
|
|
|
|
|
I'm stepping through the list of filenames retrieved fron the filedialog using GetNextPathName and GetStartPos, and for some reason it starts with the last file I selected (I'm doing a shift - click to select multiple files). Is this the expected behavior? THe order of selection is important to my app so I am wondering why it si starting from the last file selected....?
Appreciate your help,
ns
|
|
|
|
|
The first filename returned is the one that had the focus rect in the list, which will be the last name you clicked on.
--Mike--
THERE IS NO THERE IS NO BUT THERE IS
MAGIC PIXIE DUST BUSINESS GENIE CODE PROJECT
Homepage | RightClick-Encrypt | 1ClickPicGrabber
"Which comes first, the bug or the stress?" -- Chris Maunder
|
|
|
|
|
Ah I see. MAny thanks!
ns
|
|
|
|
|
I want to display a message box when the user closes the main view of a MDI framework, in order to let him know that every other view will be closed.
What method of the CScrollView derived class have I to ovveride?
Ive tried with OnDestroy, but I've seen that it's called after the window has been removed form the screen.
The OnClose method seems not to be called, as I've place a breakpoint in it.
Thanks!
|
|
|
|
|
I believe you need to handle OnCloseDocument() from with in the document not the view..
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
I don't think so, because I ant to check if I'm closing the main window, while other windows are still open. If I close the main view over a document, every other associated view must be closed.
|
|
|
|