|
|
I've already looked at that tutorial. The problem is I already have a list box set up, and if I try to change it to fixed or variable, my messages won't show up.
Is there like a command like colorRGB[255,123,210]
Uhh, thanks.
|
|
|
|
|
XP says that you have to have a username and PASSWORD(blank won't do) to be able to schedule a task
if i specify a blank password task won't saying that a blank password was given
if i don't specify username and password task still wont run
but at the same time i have norton antivirus installed it has two task both of them running and that too without password and user name
what do i do
C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do, it blows away your whole leg
http://www.mastishk.com
|
|
|
|
|
|
how can i calculate the acctuale size of a certain CString object in bytes
|
|
|
|
|
??
Is this kinda what u mean:
CString m = "a";
int size = sizeof(m) + m.GetLength() + 1; //1 for null
size will contain '6' bytes...
(4 for the internal pointer it maintains, + 1 for the "a", plus 1 for the null byte...)
Bikram Singh
|
|
|
|
|
CString s are unicode objects (each character occupied 2 bytes). Also, as I understand it, the size of a CString object is fixed, regardless of the length of the string, since memory required to store the string is obtained from the heap.
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Ravi Bhavnani wrote:
CStrings are unicode objects (each character occupied 2 bytes).
Possibly, but only with the UNICODE directive turned on i should think..
Ravi Bhavnani wrote:
Also, as I understand it, the size of a CString object is fixed, regardless of the length of the string
True, since CString contains only one pointer data member. But, Abdu's question was a bit vague ("actual size" was unclear to me, so i took a wild guess).
Bikram Singh
|
|
|
|
|
bikram singh wrote:
Possibly, but only with the UNICODE directive turned on i should think..
Yes, you're quite correct. I was hasty in replying and am also guilty (?) of always supporting Unicode.
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Works for both ansi, unicode.
CString s = _T("Hello");
int bytes = (s.GetLength() + 1) * sizeof(TCHAR);
|
|
|
|
|
|
iam making a program like Norton ghost
i want to save the files and their paths on another partition as a backup
do you have any better idea to make a program like Norton Ghost?
do know any function that copy a complete partition into backup disk?
|
|
|
|
|
For your purpose, the others said it already, it's (s.GetLength()+1)*sizeof(TCHAR) .
(however, you cannot simply pass the address of CString itself to a binary reader/writer)
we are here to help each other get through this thing, whatever it is Vonnegut jr.
sighist || Agile Programming | doxygen
|
|
|
|
|
is there any way or functions that can copy data as a low level binary from the drive to another location or drive (Norton Ghost like) .
ex: copy files and directories with out getting the path of each file and copy it to the new location i mean to get binary data from the drive direct and copy it
|
|
|
|
|
Under WinNT+, you can use CreateFile("\\\\.\\C:") to open read-only access to any disk drive (hdd or fdd), and if you know the FAT/other file system format, you can easily read data using ReadFile().
On Win9x, you can read floppies using VxD services (it's there in MSDN as an example, but i dont remember where). For reading HDD's you need to either use 16-bit code (to call BIOS functions), or write a VxD.
Bikram Singh
|
|
|
|
|
I think what you want to know is how to calculate the size in pixels the string is going to occupy on the screen
to do this just find the font's width ( i think there is a function like GetFont you could use to find it ) then multiply the font width by the number of characters in the string
|
|
|
|
|
I am working on an OSD for Girder[^]. I want my application to have some fancy 3D accelerated graphics. Is it possible in windowed mode to have per pixel alpha blending with the windows underneath in real time?
Joel Holdsworth
|
|
|
|
|
The DirectX C++ Documentation doesn't speak for or against this subject.
Apparently the only reasonable way to know for sure is to test. The Direct3D scenes are drawn in the backbuffer and then blitted to the target area. As the backbuffer can be initialized so that it's handled like a full-screen scene (although only a part of it can be blitted), then I believe all Direct3D effects are available in windowed mode as well.
-Antti Keskinen
----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
|
|
|
|
|
i m writting a C++ Win32 DLL which is called by a C# application.
i want the DLL can trigger an event to the Calling C# app after some operations which might like the Win MSG mechanism: The DLL send a message to the C# app and the C# app handle the msg.
the C# use the EventHandle/EventArgs on this issue.
But can i trigger an event to C# app in a C++ Win32 DLL ?
please help me.
|
|
|
|
|
could i grab textout api when it want to draw a text on the screen ,in this way i can buufer alll messages are printed on the screen.
|
|
|
|
|
i think you need hooks.
read some Windows Hook artical at Codeproject or
in MSDN
-----------------------------
"I Think It will Work"
Formerly Known As "Alok The Programmer" at CP
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
Possible. No easy way though. Google for APISpy32 and "Matt Pietrek".
Bikram Singh
|
|
|
|
|
By defining your own window class you get to have a HWND and HINSTANCE vars to use later. Any ideea how to get them in a dialog-based app ?
|
|
|
|
|
Hi all,
I am new to MFC.
I would like to know that how can I make Edit Box in MFC Read Only and Background of Box should be white?
Any help be appreciated .
Best Regards
Rajesh
rajesh
|
|
|
|
|
Rajesh_K_Sharma wrote:
how can I make Edit Box in MFC Read Only
editbox->SetReadOnly();
Rajesh_K_Sharma wrote:
Background of Box should be white
for changing bg color, intercept the WM_CTLCOLOREDIT message and set the HDC's(in the wParam), brush to a white brush..
Bikram Singh
|
|
|
|