|
using system() is bad. windows provides an API for consoles, but i don't remember its name...
|
|
|
|
|
Thanks for making me recall that. It was just a quick suggestion.
See Here for some information on Console's
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
I need to display Greek and English in two different CEdit controls on a dialog. How can I do this?
|
|
|
|
|
LeathurBoy wrote: need to display Greek and English in two different CEdit controls on a dialog. How can I do this?
enable UNICODE in your program
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
hi group!!
i have got one bmp file and i want to convert it to ico file
actually i want to create logo for application
so what is the way for it?
are there any readymade softwares!!
please help me
thanks and regards
harshal
|
|
|
|
|
Is this related to MFC or C++??
Why not just opening it in MS paint, and saving it in a ico format??
Regards
Programm3r
|
|
|
|
|
Have a look at CreateIconIndirect() . In the ICONINFO structure specify your bitmap as the hbmColor bitmap and create a monochrome black bitmap with the same dimensions as your bitmap for the hbmMask bitmap.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
See an example in msdn "IconPro" but im not sure it convert bmp to icon(its for extract icon form dll/exe)
|
|
|
|
|
In MSPaint do a 'select all; copy'
then in VS do 'File->New->File...->Icon file'
then 'paste'
----------------------
Mayank Thakore
Learning C++ - since 1998
They didn't print my card right; so I resigned.
|
|
|
|
|
Hi all,
Does anyone know how to create a registry entry. Nothing to complex just a normal registry entry. So if anyone knows of a site or have a small piece of code ...
Thanx in advance
Regards
Programm3r
|
|
|
|
|
Using MFC? Straight Win32?
Here's an example using straight Win32 calls. As you can see using a wrapper class as provided by MFC of ATL (and no doubt many others) would make things a lot simpler.
--------------------
// Create or open the key.
HKEY hKey;
LONG res = RegCreateKeyEx(
HKEY_CURRENT_USER,
_T("Software\\My Company\\My Product"),
0,
NULL,
REG_OPTION_NON_VOLATILE,
KEY_ALL_ACCESS,
NULL,
&hKey,
NULL
);
if (res==ERROR_SUCCESS)
{
// Now write a value in the key we opened/created.
DWORD Value = 5; // Value to write to registry.
res = RegSetValueEx(
hKey,
_T("My value"),
0,
REG_DWORD,
reinterpret_cast<const BYTE*>(&Value),
sizeof(Value)
);
// Close the key.
RegCloseKey(hKey);
}
Steve
|
|
|
|
|
Thanx for the responce.
Straight Win32, wanna put it in a win32 dll.
Regards
Programm3r
|
|
|
|
|
try ATL::CRegKey class
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
|
Thanx for the help....
Regards
Programm3r
|
|
|
|
|
Hi, i want to create an SDI application without Frame And Menu bars.
And in this SDI application ,i split the window into 3 views.
How can i close all the views at a time by clicking one button in the top view?
|
|
|
|
|
kiranin wrote: want to create an SDI application without Frame And Menu bars
Create window without using style WS_OVERLAPPEDWINDOW .
kiranin wrote: And in this SDI application ,i split the window into 3 views.
How can i close all the views at a time by clicking one button in the top view?
Look for splitterwindow.
By the way, you have posted this question already, isn't it?
|
|
|
|
|
I tried But it only closes maximize, minimize and close buttons only Still caption Bar is Coming and also menu
|
|
|
|
|
kiranin wrote: I tried But it only closes maximize, minimize and close buttons only Still caption Bar is Coming and also menu
Are you sure ?
I talked about removing style WS_OVERLAPPEDWINDOW .
Can you show me how you have implemented in your code?
One way is to 0 use ModifyStyle to remove this style in OnCreate
|
|
|
|
|
BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
if( !CFrameWnd::PreCreateWindow(cs) )
return FALSE;
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
cs.style &= ~WS_THICKFRAME;
cs.style &= ~WS_OVERLAPPED;
// optional - set initial window size
cs.cx = 400;
cs.cy = 670;
return TRUE;
}
|
|
|
|
|
Use ModifyStyle(WS_OVERLAPPEDWINDOW,0) in OnCreate of your function, instead of this.
|
|
|
|
|
How to Close and minimize the whole Application bu using a button in the top View.
And How to Paint menu or remove it?
|
|
|
|
|
kiranin wrote: How to Close and minimize the whole Application bu using a button in the top View.
send message WM_CLOSE for close button. and minimizing you need to use ShowWindow().
kiranin wrote: And How to Paint menu or remove it?
If you have use WS_OVERLAPPEDWINDOW style, there will be no menu.
|
|
|
|
|
|
kiranin wrote: menu is there yaar
You are doing some thing wrong. Try my suggestions above on sample SDI app.
|
|
|
|