will almost certainly give you a problem as strClass is not defined and not initialised. You should define it and initialise it in a similar fashion to strBuffer (e.g. set it to 250 spaces) before calling the API.Code:GetClassName hWndChild, strClass, 250
I strongly recommend you put 'Option Explicit' as the first line of all your Forms and Modules; using that statement will cause the Compiler to warn you if any variables have not been defined and you could potentially avoid problems like this.




Reply With Quote
