The date selection controls comboboxes (month and year) does not work with Firefox 3. When I click on a month, it just closes the whole date picker window, but does not update the text part to reflect the new data. The same is true with the year box. But if I use the keyboard (pressing enter after I've selected a month) it will close the combobox and update the text field correctly. And the datepicker window is still open (as it should be). I'm running Firefox 3.0 on Windows XP sp2 with the following addons: All-in-One Sidebar ColorZilla
Magnus Westin
Posts
-
Date control in Search page does not work with mouse in Firefox 3 -
std::basic_stringstreamWell, that might have been true with VS 6.0, where STL was abyssal. But since 2003 and definitely since 2005 STL and the compilers template implementation is one of the best (not the best, mind you, but ahead of most of the competition). Magnus
-
Need helpUse the following APIs RasSetEntryProperties - to create a new connection in the RAS phonebook RasDial - to dial RasHangUp - to disconnect RasGetConnectStatus - to get the status of the ras connection. Also use this after a RasHangUp to see when your handle is closed, ie when windows really is finished with your ras connection. You do that by polling RasGetConnectStatus until it returns ERROR_INVALID_HANDLE. RasDeleteEntry - to delete a phonebook entry created with RasSetEntryProperties Also note that the RAS Api is very much OS version dependant. You will see that when reading the docs for RasSetEntryProperties. I would recommend to go for minimum Win200 if you cant do that you will have much more work to do. The following RAS properties that you can set in the GUI has no function to set them. So if you really need to change them you need to update the ras phonebook file manually * Redial on link failure * DNS Suffix * MS client * MS File printer sharing * Hardware flow control * Connection speed Feel free to ask more questions if you like... Ive done a really heavy weight dialer :) Magnus
-
Pointer addressHi Theoretically there is no smallest address a pointer can point to. In windows and c++ there is. But there is no need to know that value since you should never test against it. If you get a pointer like "LPSTR pStr" you should only check that its "!= NULL". Any thing else and you should assume that it’s a valid pointer. Its to job of the person giving you the pointer to be sure he gives you a valid one. Also since this is c++ you really shouldnt use char arrays. Either use STL std::string or MFC CString when you need strings. If you really want to know about how windows handles the memory and how pointers in it work. I can recomend the following book "Programming Applications for Microsoft Windows" by Jeffrey Richter[^] Magnus
-
Memory Leak, context DeviceHi What you have there is not a regular memory leak... it could be a GDI resource leak. But that is depending on how the window class is created. If any of the following styles were used CS_CLASSDC, CS_OWNDC or CS_PARENTDC, then the above is not a resource leak, other wise you should use ReleaseDC to reclaim the GDI resources. Also for you information, VS C++ will not report GDI resource leaks only normal memory leaks from the built in memory handler. Magnus
-
max number of threads/Win32 processnope... no hard limit. But you are going to run out of memory. Default each thread has a 1MB stack... so go from there. Also performance vise is that too many threads running (and doing stuff) you will start to loose so much time in the thread switches that the system will grind to halt. Magnus
-
Explorer View - TimeTakingWell thats the only way I know of speeding up the list control. Except a full owner draw version... but thats an even bigger change :) When are you populating the control.. maybe if you wait with that untill after the call to ShowWindow... might help. Magnus
-
Explorer View - TimeTakingFor the list view, check LVS_OWNERDATA in MSDN docs. Its a style to make a virtual listview. That could solve your problem. I dont think there is any thing similar for the tree view. Magnus
-
Changing IP, gateway, etc programaticallyI too have been looking in to it. And havent found any way... well except writing a kerner driver. So I use the "netsh" command. I think its available on all windows installations. You can change the IP for the current window session with the help of the IPHelper API (MSDN has examples of its use). But I guess you want to change it permanently. This is how you would write to change the IP address. netsh interface ip set address static Magnus
-
TLS in a static libraryWhy not make a Thread class where you put the Tls functionality. And if all your threads is started from that class you shouldnt have any problem destroying the Tls when the Thread object is destroyed. Never do global stuff... it really hurts the design. Magnus
-
How to access remote database server from windows serviceIt would make this question much easier to answer if you could at least post the error you get when you try to access the database. But if I have to guess, I would think that you are using the default service account. That account doesn't have rights to access the network, instead you should create a user with normal user rights, and use that user with your service. Magnus
-
Mozilla Firebird problemThanks, it worked out great. //Magnus
-
Mozilla Firebird problemHi I changed to Firebird yesterday. And when I logged on the Lounge I get this message: Hint: For a faster board use IE 4+ or Mozilla, choose 'Dynamic' from the View dropdown and hit 'Set Options'. The problem is, with Firebird there is no Dynamic option (Ive tested with IE, and I have it there). Any one else having this problem? Or do I have to go back to IE again. //Magnus
-
Shell_NotifyIcon problem.. Help Techies!!There can be several problems, but the most likely is that you dont get the notification about the tray creation. Following is from MSDN: Taskbar Creation Notification With Internet Explorer 4.0 and later, the Shell notifies applications that the taskbar has been created. When the taskbar is created, it registers a message with the TaskbarCreated string and then broadcasts this message to all top-level windows. When your taskbar application receives this message, it should assume that any taskbar icons it added have been removed and add them again. This feature generally applies only to services that are already running when the Shell begins execution. The following example shows a very simplified method for handling this case. So you will need to do this and then handle that message m_nTaskbarCreatedMsg = ::RegisterWindowMessage( "TaskbarCreated" ); And take a look at Chris Maunder excellent class http://www.codeproject.com/shell/systemtray.asp[^] Magnus
-
createProcess questionsQ1: Yes Q2: Depends. If your code is called from the application thread (the one with the message loop), then yes it will block your app until the launched app exits. But if you call it from an other thread then your app will not block. Magnus
-
Weird problem with FindFirstChangeNotificationThe reason for this small test program was that I read on google about a possibility that you could not delete a directory that has a FindFirstChangeNotification watch on it. As it turned out, its no problem at all (at least on WinXP). But I noticed another stranger thing. When I delete the directory in Explorer, the HANDLE is set to signal state and I get a continuous flow of "Something happened". But when I delete the directory in Total Commander (new name for Windows Commander) I get error 5 (Access is denied.) from FindNextChangeNotification. And the program ends. This is not really a question, since the correct implementation should check that the director (or file) you are watching still exists. But what really bothered me were the different results from Explorer and Total Commander. So I wondered if some one else has had this problem or if some one knows why this happens. Here is the small test program I ran while deleting the directory (its written in Visual Studio 6.0 sp5):
int main( int argc, char* argv[] ) { HANDLE h = ::FindFirstChangeNotification( "d:\\test\\magnus", FALSE, FILE_NOTIFY_CHANGE_FILE_NAME ); if( h == INVALID_HANDLE_VALUE ) { std::cout << "Error on FFCN: " << ::GetLastError() << std::endl; return 0; } std::cout << "Entering loop" << std::endl; for( ;; ) { DWORD dwWaitState = ::WaitForSingleObject( h, INFINITE ); switch( dwWaitState ) { case WAIT_OBJECT_0: std::cout << "Something happened" << std::endl; break; case WAIT_ABANDONED: std::cout << "Error WAIT_ABANDONED" << std::endl; break; case WAIT_TIMEOUT: std::cout << "Error WAIT_TIMEOUT" << std::endl; break; default: std::cout << "Error DEFAULT" << std::endl; break; } if( dwWaitState != WAIT_OBJECT_0 ) break; if( ::FindNextChangeNotification( h ) == 0 ) { std::cout << "Error on FNCN: " << ::GetLastError() << std::endl; break; } } ::FindCloseChangeNotification( h ); return 0; }
Magnus
-
Own TrayWhat is Own Tray? I have never heard of this. Magnus
-
Help...win 98 to win XPIf you are going to do a unicode project then all strings must begin with L eg. L"Part Files(*.asm)|*.sldasm||" to tell the compiler you want a wide string. But I would recommend you read up on TCHAR, that way you can compile your program in both UNICODE and single byte mode. I dont know any good unicode resource on the web, but if you are going to do a unicode project, then I recommend you read some books on the subject. Its a lot more to unicode than meets the eye. Also here on codeproject is http://www.codeproject.com/cpp/unicode.asp?target=unicode[^] http://www.codeproject.com/vcpp/stl/upgradingstlappstounicode.asp[^] Magnus
-
Help!!!in Windows XP sp1 and Windows server 2003 you can call GetProcessId. But for the other, I dont think there is a documented way of doing that. You might be able to doing with some kernel call, but Im not sure. If there is a way, search Google under microsoft.public.win32.programmer.kernel Magnus
-
Problem with threadyour while loop will generate 100% cpu, since you dont have any kind of blocking code inte CtestDlg::Start. What the CPU is doing is calling Start all the time. Magnus