|
What is the best method of preventing the download of certain elements of a web page (ie .gif, .jpg, .mpeg). I'm sure it's relativly simple, but I'm not too up to date on COM so it gets very confusing trying to go thru the documentation and the samples are not too helpful. Any thoughts would be appreciated.
|
|
|
|
|
I need a MFC class implementing a scrollable window inside a dialog. Any idea ?
|
|
|
|
|
Even a CWnd could be OK... It depends on what you want to do with that window!
If you are more specific you get more specific answers
|
|
|
|
|
I have MSVC++ 5.0 I want a RELIABLE method of detecting the number of buttons a mouse has within my program (inclusive of the Intellimouse Explorer), that will work under Windows 95/98/2000 and NT! I already know the following:
1.)Win32 will always report 2 mouse buttons no matter what type of mouse is connected to the system.
2.)Attempting to use the following code:
if ((hMouse = GetModuleHandle ("MOUSE")) != NULL)
lpfnInquire = (LPFNINQUIRE) GetProcAddress( hMouse, "Inquire" );
This technique will only work if MOUSE.EXE is specified as being loaded under the WIN.INI file! (Most people don't do this anyway, at least under 95. And I don't want to mess up other people's systems by writing to the WIN.INI!)
3.)I DO NOT want to have a list of every possible mouse type that can be connected to the system! (hoplessly dating my program!)
There should be a way (short of writing my own mouse driver) that I can detect the mouse driver and obtain this (number of buttons) information. What is it?
|
|
|
|
|
Where did you get the info that the OS always returns 2 buttons? Both GetNumberOfConsoleMouseButtons() and GetSystemMetrics() return 5 for my IM Explorer me on 2K.
|
|
|
|
|
Still in need of an answer! Will not work under Windows 95!!! (I know, I tried BOTH, and both give the same answer (2 buttons))! The app I am designing is to be a mouse/keyboard remapper, and is to be TSR (so I can't play tricks like capturing the mouse in a screen and disecting the packet structure!) Need help please! I've wasted a week already on this problem!
|
|
|
|
|
How to find no of comm ports available in the system? (apart reading from the registry)
thanks in advance.
|
|
|
|
|
2 questions
1) I have a Rich edit control in a dialog box. I add text to the end through a CString. I want to keep the scroll position it the bottom of the text. Whenever you call UpdateData (FALSE); it springs back to the top of the text. I've had a look at the setscrollpos, etc (that are in CWnd), but they are not very effective.
2) In the rich edit control i want to have different colours, but since the user does not enter text directly i use updatedata and all formatting is lost (and all text goes to the last setting used). Anyway around this?
thanks
|
|
|
|
|
for question #1
Have you tried the LineScroll() member function ?
For example, after UpdateData(FALSE);
int nVis = m_edit1c.GetFirstVisibleLine();
int nscroll = m_edit1c.GetLineCount() - nVis;
m_edit1c.LineScroll(nscroll);
(assuming that you have a control variable,
m_edit1c, associated with the Rich edit control)
|
|
|
|
|
I've tried to implement an Unicode program, to read and write Unicode character, but when I compile the program, this is the error message :
msvcrtd.lib(wcrtexew.obj) : error LNK2001: unresolved external symbol _wWinMain@16
Debug/DAS Converter.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
I already define _UNICODE, and also use wWinMainCRTStartup as the entry point.
Please help me,
Thanks
|
|
|
|
|
I have in an application several List controls. I don't want scrollbars, even when all the content of the list is not visible.
I have tried different ways but I didn't find the solution.
I did this with CListBox with no problems but list controls are different.
The LVS_NOSCROLL style is not what I want, because I still want to be able to scroll programatically.
I would appreciate a hint.
Best regards
Jose
|
|
|
|
|
1. What are the minimum requirements to use 'Microsoft Web Publishing API' programs? To run a application developed using this API what do I need to have installed? I could not find this info anywhere.
2. The following code segment crashes with a 'Unhandled exception in <whatever>.exe[WEBPOST.DLL]: 0xC0000005: Access Violation.', after WpPost is called. I have Administrative privileges on my system.
<code_segment>
char *fname[] = {"E:\\workdocs\\book.xml"};
LPTSTR szLocalPaths = NULL;
szLocalPaths = *fname;
LPTSTR szSiteName = NULL;
char *dname[] = {"http://160.86.13.190/"};
LPTSTR szDestURL = NULL;
szDestURL = *dname;
lReturn = WpPost(NULL, 1, &szLocalPaths, 0, NULL, 0, szDestURL, WPF_NO_UI);
<\CODE_SEGMENT>
What am I doing wrong here?
Thanks,
Sai
|
|
|
|
|
You need to have the web post installed on the client machine to post files to a server.
Search MS web site for this client-related download :
pa20setup.exe - Web post acceptor
Keyword search for "web publishing wizard" and "web post"
You need to have web server extensions installed to the server machine to accept web publishing.
Use these links to get started on server side :
Resource Kit
officeupdate.microsoft.com/frontpage/wpp/serk/adoview.htm
Download
msdn.microsoft.com/workshop/languages/fp/2000/winfpse.asp
I recently had to get all this sh*t programmatically installed to a machine, so there are definitely two parts required - one on each end. You are probably more interested in the client portion for now.
|
|
|
|
|
Hi,
I wanr ro disable the Copy and Drag operations in Webbrowser control . One way of doing it is in Pretranslatemessage of Webrowser container we can trap the CTRL+C and WM_LBUTTONDOWN AND disable them. Is there any other way of doing it ????.
Thanxs in advance.
Balak
|
|
|
|
|
I have designed and implemented a set of services for NT. I used the ATL COM wizard to create the skeleton and then fleshed it out with my desired Run() actions. I want to make ( and have tried to ) several user-defined controls. Whenever I call the ControlService() API I get ACCESS_DENIED. I have domain admin rights on both machines so I do not think NT security is the issue. I obtained a service handle using OpenService. I have passed EVERY combination of SERVICE_ACCEPT_ flags to OpenService
including SERVICE_ALL_ACCESS. None of them work. All of them result in GetLastError() = 5 ( ACCESS_DENIED ). I am able to START and STOP the service but all other controls fail. I have noticed that the SERVICE_STATUS returned after opening indicates that only STOP controls are accepted. Could some kind soul out there enlighten me on how to get PAUSE, CONTINUE, and USER-DEFINED controls to work for the ATL NT service model ? Please send any reply to my email address ( although I will check this site as often as I can ). If you have a good example of a
service ( source code ) then send it along.
Many thanks,
Robert
|
|
|
|
|
Hi,
How do i disable the PrintScreen and Print functionality in a dialog based MFC application???. Can anybody
enlighten me about this
|
|
|
|
|
In a dialog, i have some buttons and a CEdit control. How would I set the focus to the edit control?
tanx
|
|
|
|
|
|
okay, whoops, i should have said that i have a CString mapped to the control. I suppose I have to map a CEdit as well to be able to focus it...
|
|
|
|
|
What does it mean 'to have a CString mapped to the control' ??? If you'll be more specific maybe I'll help you
Honza
|
|
|
|
|
i meant that in Class Wizard member variables i put a CString onto the edit box. I put a CEdit onto the edit box as well, so i can use SetFocus like that. I was just wondering if you could do it without having to have a CEdit just for that. if u get what i mean .
|
|
|
|
|
CEdit* pEdit = (CEdit*)GetDlgItem(IDC_EDIT);
pEdit->SetFocus ();
|
|
|
|
|
Two ways:
1. GotoDlgCtrl ( GetDlgItem ( IDC_MY_EDITBOX ));
2. GetDlgItem ( IDC_MY_EDITBOX )->SetFocus();
|
|
|
|
|
Use this:
GotoDlgCtrl(GetDlgItem(IDC_MYCONTROL));
That way, you don't need to setup a member variable of the control type...
|
|
|
|
|
How can I set separately any Video for Windows parameters (Brightness,Saturation,Contrast, Hue and others)
from my application without vfw standard dialogs?
ok@aquanet.co.il
|
|
|
|