简体   繁体   English

CScrollbar可在一台PC上运行,但不能在其他PC上运行

[英]CScrollbar works on one pc but not on any others

I've written some code in c++ using a CScrollbar which scrolls a CWnd and treeview at the same time. 我已经使用CScrollbar用C ++编写了一些代码,它同时滚动了CWnd和treeview。 This works perfectly find on my pc, but on other pc's in the office it has problems: 这可以在我的电脑上找到,但是在办公室的其他电脑上却有问题:

  • it only scrolls up 它只会向上滚动
  • it allows the user to scroll when they don't need to 它允许用户在不需要时滚动

I've tested this on Vista, XP, and Windows 7 and they all have the same result. 我已经在Vista,XP和Windows 7上进行了测试,它们都具有相同的结果。 My pc is running Windows XP. 我的电脑正在运行Windows XP。

My question is: do you know what might be the cause, and if not, how might I go about finding the cause? 我的问题是:您知道可能是什么原因,如果不是,我将如何找到原因? I don't really know where to start. 我真的不知道从哪里开始。

The only thing I can think of would be an uninitialised variable. 我唯一想到的就是一个未初始化的变量。 Potentially in one of your SetScrollInfo calls. 可能在您的SetScrollInfo调用之一中。 eg Are you setting the fMask member of SCROLLINFO correctly? 例如,您是否正确设置了SCROLLINFO的fMask成员?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM