|
How to hide cursor for a while?
Kaldoklv
|
|
|
|
|
int ShowCursor(
BOOL bShow // cursor visibility
);
bShow=FALSE
|
|
|
|
|
Hi,
I'm working on a project which calls a Word instance in a view in the program (the programmer who made it used smartpointers). This works fine for Office 97 -> Xp, but it DOESN'T work with Office 2003(sometimes it does, mostly it doesn't). My colleagues and I cannot find the problem.
Does anyone know what may be the problem? How do we solve it?
Re-writing the complete code is not really an option.
extra info: when terminating the program I get an acces violation error. The contents of the address called in the assembly is empty.
tnx for your help!!
|
|
|
|
|
Can't really help, but that sounds like exactly the sort of thing I need to do for a current app - can you give me any pointers as to how you've acheved it? Pretty Please???
"Now I guess I'll sit back and watch people misinterpret what I just said......"
Christian Graus At The Soapbox
|
|
|
|
|
I cannot explain how you use smartpointers as I don't understand them really well myself.
However there is a second way for automation.
You have to "import" the library stuff from office itself. (for word 2003 it's the MSWORD.OLB file) These contain all the functions available for working with Word. (cfg Excel, Acces, ...) If you succesfully imported them you can make Objects of the the Word application and use them as any other Object. (see msdn for more info)
You have to read a lot of that stuff to understand it all. There are also examples on msdn.
(btw I found my error, if you get the same, try pressing ALT-F5)
there is also an object model file called VBAOF11.CHM (again office 2003) in your office. Here you can find additional info.
hope it's helpfull (but to explain it all it's just TOO much)
|
|
|
|
|
You should ask me, I can get you answers wholesale, with reduced delivery costs...
If you drop me an email to my hotmail account, with a rough outline, I'll send you back a (hopefully useful) set of instructions/hints.
Steve S
|
|
|
|
|
|
Read the posts?
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
sorry
|
|
|
|
|
Nevermind dude
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
I'm looking for a function that gives me a list similar to what I get from Add/Remove Programs.
WinXP; any help greatly appreciated.
|
|
|
|
|
char textds[250];
CWnd *DT = GetDesktopWindow();
CWnd *NW=DT->GetTopWindow();
for(;;)
{
NW=NW->GetNextWindow();
if(NW==NULL) break;
NW->GetWindowText(textds,sizeof(textds));
//here you have a pointer to the window
}
|
|
|
|
|
I am going to add a small article on how to do this, but the following code fills an MFC CStringList with the installed programs:
<br />
#define AUDIT_KEY _T("Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall")<br />
#define AUDIT_KEY_LEN 256<br />
#define AUDIT_DISPLAY _T("DisplayName")<br />
<br />
<br />
HKEY hKey;<br />
if (::RegOpenKeyEx(HKEY_LOCAL_MACHINE, AUDIT_KEY, 0, KEY_READ, &hKey) != ERROR_SUCCESS)<br />
return;<br />
<br />
CStringList list;<br />
<br />
DWORD dwIndex = 0;<br />
LONG lRet;<br />
DWORD cbName = AUDIT_KEY_LEN;<br />
TCHAR szSubKeyName[AUDIT_KEY_LEN];<br />
<br />
while ((lRet = ::RegEnumKeyEx(hKey, dwIndex, szSubKeyName, &cbName, NULL,<br />
NULL, NULL, NULL)) != ERROR_NO_MORE_ITEMS)<br />
{<br />
if (lRet == ERROR_SUCCESS)<br />
{<br />
HKEY hItem;<br />
if (::RegOpenKeyEx(hKey, szSubKeyName, 0, KEY_READ, &hItem) != ERROR_SUCCESS)<br />
continue;<br />
TCHAR szDisplayName[AUDIT_KEY_LEN];<br />
DWORD dwSize = sizeof(szDisplayName);<br />
DWORD dwType;<br />
<br />
if (::RegQueryValueEx(hItem, AUDIT_DISPLAY, NULL, &dwType,<br />
(LPBYTE)&szDisplayName, &dwSize) == ERROR_SUCCESS)<br />
{<br />
list.AddTail(szDisplayName);<br />
}<br />
::RegCloseKey(hItem);<br />
}<br />
dwIndex++;<br />
cbName = AUDIT_KEY_LEN;<br />
}<br />
::RegCloseKey(hKey);<br />
The Rob Blog
|
|
|
|
|
Hi all.
Whether exit simple function like WIDTH(RECT rc) in standard VC libraries ???? I.e functions what accomplish
an plain operations with RECT structure ,get width ,get height.This not hard to write any makros for this aim but i just want think.
Thaks.
|
|
|
|
|
I know that under MFC you have a class CRect for it
but under API Win32 i dont think there is
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
I would like to override the minimize-event so that the dialog remains where it is but resizes to a fixed size (e.g. CRect( x, y, 320, 100 ) )
How is that possible?
I’ve tried this but don’t get the ” CRect( x, y, 320, 100 )”-size
void CDlg::OnSize(UINT nType, int cx, int cy){
if( nType == SIZE_MINIMIZED )
{
CPoint p;
GetCursorPos( &p );
SetWindowPos( 0, p.x, p.y, 320, 100, 0 )
return;
}
…
…
}
...and justice for all
APe
|
|
|
|
|
Try the function OnGetMinMaxInfo() and override the values of MINMAXINFO FAR* lpMMI->ptMinTrackSize.x,y
this shud the fix the dialog to the min size set by you in the above function
Gudluck
Adi
|
|
|
|
|
Hi,
I am doing a dialog based app USING MFC.
I need to interact with the front end using Flash.
Can anybody help me in this regard?
The flow of app is .....
Create a Dialog based app
Insert a Flash based control.
Insert a Flash control "buton".
Pls help me in communicating with these two.
Regards
|
|
|
|
|
How can you tell if a CWnd object is displayed or not. I can never figure this one out.
If you initilise the object but not displayed as a window what function can I call to test it?
---
|
|
|
|
|
May be it's need to check WS_VISIBLE style flag, true or false, setted or not ?
|
|
|
|
|
BOOL CWnd::IsWindowVisible();
Maxwell Chen
|
|
|
|
|
Thanks, that was rather stupid of me
---
|
|
|
|
|
Where can I get/download DBG files for MS VS 7, C++
I need exact link/URL.
Now i'm walking on www.microsoft.com and while i have no results
Thanks a lot in advance !!!
|
|
|
|
|
|
COOL!!! MEGA THANKS !!!
Thanks a lot again many times !
Navigation of MS site very hard for me (
|
|
|
|