Thursday 28 April 2016

Mouse Moves On Its Own Problem


There are various reasons as to why a mouse cursor just moves by itself.  One can just suspect a computer infestation as the reason but that can be possibly ruled out by going through the following questions:
  1. Does my pc have an anti-virus?
  2. Is the virus definition updated?
If you’ve answered yes to both questions, then your computer is okay unless the virus is new. To check if the problem is coming from something else,  you can also try and replace your mouse with a new one. If the problem persists then you can still keep that old mouse.

Another way to fix this is to try and uninstall and reinstall the mouse driver and see if it clears up the problem. A corrupted driver can sometimes mess things out.

To uninstall and reinstall the mouse driver, do the following steps:  (The example below is made using Windows XP OS. Win7, 8 and 10 have similar entries in Device manager anyway.)

Let’s assume you’re using a USB mouse. Unplug it and use the keyboard (shortcuts) to navigate to everything. 

Note: Since your mouse is not working during this time, you'll have to rely on the keyboard alone. We can simulate basic mouse movements by pressing the TAB key, for instance, to move through folders and files; the Menu Key for Right+Click and Enter key for double click. So when I say, Right+Click, you actually have to press the Menu Key which is situated in between the Alt key and Ctrl Key.

Right click on My Computer and select Properties. Once the System Properties is up, click on the Hardware tab and click on Device Manager.



Find the Mice and other pointing devices. Expand on the node to see the installed driver. In this case, mine’s  HID-compliant mouse.


Now, right+click on it and select uninstall.


Plug the mouse again. The mouse should be working fine again. 90% of the time, this works for me. 


Another Reason for Mouse Moving On Its Own


Sometimes, the mouse can also have a faulty cable. The fault can be unnoticeable but can prompt the computer to install a newer but exactly the same driver for your mouse causing it to conflict with the old driver. This may result to, say, an intermittent shaky mouse cursor.

When that happens, you'll see something like this in the device manager when you access it.





To fix that shaky mouse problem, right+click on one of the two drivers and disable it, leave the other one alone.





A disabled driver will have a red X mark on its icon.  This action may instantly get rid of that pesky unwanted mouse moving. Hope this helps. 



Friday 15 April 2016

How To Enable Intellisense In SQL Server Management Studio 2008 R2


The intellisense is a feature in SQL Server Management Studio 2008 R2 (SSMS) that assists T-SQL developers to easily know the underlying tables or fields of a database when typing codes from within the query editor.  Functions and variables may also popup as soon as you begin typing one or the first two letters of the keyword.

Some may find it weird that even after having  SSMS configured to enable this feature, it just won't work. My best guess is that their SSMS isn't upgraded to SP3 yet. To upgrade the SSMS 2008 R2 to SP3, please visit this download link and choose the appropriate platform for you.

Once installed, restart your SSMS and check for the following settings. Go to TOOLS menu and select OPTIONS.

This section is under Transact-SQL. The checkbox for "Enable IntelliSense" should be ticked.

By this time, the intellisense should kick-in. If not, please check if "IntelliSense Enabled" is clicked  under the Query menu. The icon is sunken if it is enabled.


Lastly, try to refresh the IntelliSense local cache by pressing Ctrl+Shrft+R while in the query editor. I hope that you were able to get your IntelliSense working.

Until next time! 

Friday 8 April 2016

How To Select All Nodes In Treeview In VFP 9.0


A more appropriate title of this article should have been  "How To Check All Child Nodes From a Parent Node In Treeview" but since I used a treeview control that contained only one parent node with multiple child nodes within, I guess I'd stick with the current title.

Here's one way I achieve the effect. But before I show the code behind, take note of the underlying table records where the treeview gets its record from.


The parent node has a "02_" string as a key as shown from the highlighted row in the image above. All the child nodes have different keys but have the same parent, a "02_" text that is used as a pointer to their parent node.

In the Treeview's .NodeCheck event, I wrote the following codes.

*** ActiveX Control Event ***
Lparameters Node
If Node.Key <> '02_'
      Return
Endif

For Each oNode In Thisform.oletreeView.Nodes
      oNode.Checked = Iif(Node.Checked,.F.,.T.)
Endfor

You can see that I added a checking routine to know if the user is ticking on the parent node or the child node. If the user has checked any of the child node, it will stop from there and will not proceed to executing the next codes, hence the "Return" keyword.

Next, I reiterate through all the treeview's nodes and set each node's checked property to either TRUE or FALSE depending on the parent's current "checked " status. If the parent's checkbox is unticked, the current child node in focus during which is set to checked; otherwise, it is unchecked.

Here's the result of which.


Related Posts Plugin for WordPress, Blogger...