Dear Infragistics Experts,
I am facing a problem concerning the scrollbar. It seems not working well in Chrome. I have the feeling that some internal feature of Chrome prevents the scrollbar from behaving normally.
Please open the following sample page by Chrome, check the "Enable Scrollbars", and try to directly drag the scrollbar. Then you will see the problem.
http://samples.infragistics.com/2010.3/WebFeatureBrowser/contents.aspx?showCode=true&t=WebCharts/Axis/AxisScrolling.aspx~srcview.aspx?path=~srcview.aspx?path=WebCharts/Axis/AxisScrolling.src
Except disabling the scrollbar, is there any way I can workaround this issue?
Thank you,
Ziming
Hi,
The problem comes from the fact that the scrollbar element goes selected. You could prevent this by the following code:
<head runat="server">
<title></title>
<script type="text/javascript">
function Load() {
var IsIE8 = navigator.userAgent.toLowerCase().indexOf("msie 8") != -1;
if (IsIE8 == false) {
document.onmousedown = function() {
return false;
}
</script>
</head>
<body onload="Load()">
<form id="form1" runat="server">
….. the rest of the code….
I hope that helps.
Hi Petia,
Thanks for your reply. I tried your code, and it successfully resolved my problem.
In order to minimize the impact, I slightly adjusted your JavaScript method as below.
$(document).bind('mousedown', function(e) { var scrollbarId = String.format( '{0}_SB1_engagable', '<%= ucMainHistogram.UniqueID %>'); var targetId = $(e.target).attr('id'); if (scrollbarId == targetId) { return false; } });
Thank you again for helping me tackle this issue.
Best regards,
Hi Ziming,
Note that this is messing with the scrollbars logic and if you want it to work cross browser you should not call this when in IE.
I see. I will further improve my code and not to call it in IE.