Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @0",
vbNormalFocus)
Regards,
Peter T
"art" <(E-Mail Removed)> wrote in message
news:BBDF8A81-866D-4A04-8FBB-(E-Mail Removed)...
> Thanks. What I wanted was the window "C:\Windows\system32\main.cpl" that
> is
> the mouse option window to display. Can you tell me how to write that.
>
> "Peter T" wrote:
>
>> Private Declare Function SwapMouseButton Lib "user32" (ByVal _
>> bSwap As Long) As Long
>>
>> Function DefMouseButton(Optional nButton As Long = 0)
>>
>> DefMouseButton = SwapMouseButton(nButton)
>> End Function
>>
>>
>> DefMouseButton 1& ' right
>> DefMouseButton 0 ' left
>>
>>
>> Regards,
>> Peter T
>>
>> "art" <(E-Mail Removed)> wrote in message
>> news:933B2E6B-F2EC-438C-9142-(E-Mail Removed)...
>> > Hello:
>> >
>> > I was wondering how I can write a VBA code that will allow me to change
>> > the
>> > mouse options in the control panel that switches primary and secondary
>> > buttons. How can I access the control panel from excel? Please let me
>> > know.
>> >
>> > Thanks.
>>
>>
>>
|