|
You're welcome!
bions wrote: I wish the documentation was easier to plod through to find simple solutions like this so I wouldn't have to waste two days and then have to ask anyway.
We all do
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I need some quick help and i thought of the guru's on this forum. My cd/dvd rom won't read or write to Blank CD's. It reads Blank DVD's but says the file system is raw and has 0 bytes on the blank 4gb dvd.
I've tried to uninstall the cdrom and then searched for added hardware, but still nothing. what can i do?
|
|
|
|
|
You may want to try posting this on the Hardware board.
That's my quick help
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
But why did it take you three minutes to provide said help? Come on, Mark, that's not the philosophy around here.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I'm getting slow in my old age
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
hi everybody
how can i send data in mysql data base through mfc dialog based application.
i am new for mfc and mysql please guide me with some code and example
I will be more obliged .
regard
malik
|
|
|
|
|
rajneshmalik wrote: please guide me with some code and example
You are in luck. CodeProject is all about guides and example code. There is a massive amount of Database related articles here. Now all you need to do is look around the CodeProject Web Site, locate the list of articles and start working! To do that there are what is called "links" on these pages that you can "read" and then "click on" to navigate around the site. GOOD LUCK!
|
|
|
|
|
Hi,
Is it possible to write an dll, which can be accessed both from exe and webpage(using ASP)?
Regards,
John.
|
|
|
|
|
Try developing a COM dll..
Cheers,
Suresh
|
|
|
|
|
Hi,
I have the following situation:
I hide some columns of a CListCtrl derived object. I do this by setting the column width to zero
with the code :
BOOL CXListCtrlHead::SetStdColWidth(int nCol, int nWidth)
{
ASSERT((nCol >= 0) && (nCol < GetItemCount()));
ASSERT(nWidth >= 0);
HDITEM hdi;
memset(&hdi, 0, sizeof(HDITEM));
hdi.mask = HDI_WIDTH;
hdi.cxy = nWidth;
return SetItem(nCol, &hdi);
}
when I want to do the drawing by overridding OnCustomDraw()
the code :
CRect rc;
GetSubItemRect(nItem, nSubItem, LVIR_BOUNDS, rc);
TRACE(_T("Width = %d\n"), rc.Width());
gives me an output of "Width = 16"
The subitem for which I am asking the bounding rectangle is the column I set to zero earlier.
btw I am using the code from http://www.codeproject.com/listctrl/xlistctrl.asp
How is this possible ?
tia
|
|
|
|
|
You might consider posting this under the xlistctrl article - you may get help quicker there.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
Save an Orange - Use the VCF!
VCF Blog
|
|
|
|
|
Dramas,
I've subclassed CToolBar to custom draw toolbars & I've worked around most of the quirks but I'm somewhat stuck when it comes to drawing the down arrow on a button with the BTNS_WHOLEDROPDOWN style or BTNS_DROPDOWN with TBSTYLE_EX_DRAWDDARROWS on the toolbar.
From a bit of experimenting in XP I've found:
BTNS_WHOLEDROPDOWN with TBSTYLE_AUTOSIZE on increases a button's width by 6
BTNS_WHOLEDROPDOWN with TBSTYLE_AUTOSIZE off increases a button's width by 7
BTNS_DROPDOWN with TBSTYLE_AUTOSIZE on increases a button's width by 19
BTNS_DROPDOWN with TBSTYLE_AUTOSIZE off increases a button's width by 18
(I'm assuming some of the 18/19 is padding but how much?).
After playing with CToolBar::SetMetrics, I can confidently say that the toolbar & button padding settings do not affect the drop-down width but I can't find any documentation on how to query the O/S for the drop down width, or whether any system settings (e.g. themes) or other O/S versions will give different values.
Is there something I've missed? Or can anyone confirm whether the drop down widths listed above are always true?
-- modified at 10:02 Friday 10th August, 2007
T-Mac-Oz
|
|
|
|
|
You can easily use FindFirstChangeNotification() in your MFC applicaton just like you would with any other Win32 API.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi,
On creating registry key, a string value named "(Default)" is automatically generated, whose data is "value not set" means no value, how can I assign some data to that value programmatically.
Best Regards,
Mushq
Mushtaque Ahmed Nizamani
Software Engineer
Ultimus Pakistan
"English is my second language; please excuse any grammatical or spelling mistakes"
|
|
|
|
|
Mushq wrote: how can I assign some data to that value programmatically.
By using RegSetValue(hKey, "", ...) .
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
David, Thanks a lot
Best Regards,
Mushq
Mushtaque Ahmed Nizamani
Software Engineer
Ultimus Pakistan
"English is my second language; please excuse any grammatical or spelling mistakes"
|
|
|
|
|
Hey I'm trying to use the Accessible Object API to find out when an event happens in an IM window, I've got some visual basic code for it but when i try to do this in a console applications it doesn't work. I know its probably something to do with the infinite for loop but i have no idea how else to do this and wait for some events to be printed into the console, heres the code i mainly got from msdn.
<br />
HWINEVENTHOOK g_hook;<br />
<br />
void CALLBACK HandleWinEvent(HWINEVENTHOOK hook, DWORD event, HWND hwnd,<br />
LONG idObject, LONG idChild,<br />
DWORD dwEventThread, DWORD dwmsEventTime)<br />
{<br />
printf("called\n");<br />
IAccessible *pAcc = NULL;<br />
VARIANT varChild;<br />
HRESULT hr = AccessibleObjectFromEvent(hwnd, idObject, idChild, &pAcc, &varChild); <br />
if ((hr == S_OK) && (pAcc != NULL))<br />
{<br />
char *classname;<br />
classname = (char*)malloc(15);<br />
GetClassName(GetParent(hwnd),(LPTSTR)classname,14);<br />
printf("Classname: %s\n", classname);<br />
if(strcmp(classname,"IMWindowClass") == 0){<br />
printf("found\n");<br />
}<br />
<br />
}<br />
}<br />
<br />
void InitializeMSAA()<br />
{<br />
CoInitialize(NULL);<br />
g_hook = SetWinEventHook(<br />
EVENT_SYSTEM_ALERT , EVENT_OBJECT_ACCELERATORCHANGE,
NULL,
HandleWinEvent,
0, 0,
WINEVENT_SKIPOWNPROCESS);
}<br />
<br />
int main(array<System:(Smilie)tring ^> ^args)<br />
{<br />
InitializeMSAA();<br />
printf("init'd\n");<br />
while(1);<br />
system("pause");<br />
return 0;<br />
}<br />
Any help would be great!
|
|
|
|
|
I am using TextOut() fun but it's taking Black as a default colour
can anybody tell me how to change it's colour????
Thanks!!!
There Is Nothing Right & Wrong
|
|
|
|
|
Use of SetTextColor for text color and SetBkcolor for background color.
|
|
|
|
|
Hello every1,
I m trying to develope an application in MFC which deletes all Internet cookies .I am using Firefox. Can u plz suggest me how can I do that?
Plz reply me as soon as possible.
Thanks.
s_v_patel
|
|
|
|
|
|
tht's fine for IE ..but that is not gonna work for FireFox... want some functions in MFC which actually retrives cookies stored on my machine n delete them.
Thanks.
s_v_patel
|
|
|
|
|
Where are those cookies stored? This is not a rhetorical question. You just might have to search the HD to find them. But without that information, deleting said files won't be possible.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Of course those cookies r stored on my machine. I want a fuction in MFC which retrieves internet cookies and delete them.
I have mane application for Internet explorer but not for FireFox..
Thanks.
s_v_patel
|
|
|
|
|
s_v_patel wrote: I want a fuction in MFC which retrieves internet cookies and delete them.
Such a function does not exist. You will need to create your own.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|