寻找日程安排/日历组件
我正在寻找 Delphi 7 的自定义可视组件,它可以处理日历上的日程安排。我不是在寻找实际的日历,也绝对不是在寻找一些经过彻底修改的许可组件。我只想要一个简单的视觉组件,带有类似轨迹栏的项目列表。例如,在左侧,我可以列出员工姓名。每条记录都跨越控件。右边的X轴代表时间,每个员工(Y轴)记录可以有多个时间段(开始..结束),这些时间段不仅显示在员工的右侧,而且用户可以调整每个时间段的大小,拖动它们、删除它们等等。它显然将用于这个确切的目的,用于安排员工工作时间。我不需要任何与其他东西集成的东西,例如数据库,我可以自己完成所有工作。我只想要一个简单的控件,可以用于直观地创建这样的时间表。
I'm looking for a custom visual component for Delphi 7 which handles scheduling on a calendar. I'm not looking for an actual calendar, and I'm definitely not looking for some overhauled licensed component. I just want a simple visual component, with a trackbar-like list of items. For example, along the left, I could have employee names listed. Each of those records stretches across the control. To the right, the X axis represents time, and each employee (Y Axis) record could have multiple time periods (start..finish), which are not only displayed to the right of the employee, but also user can resize each period, drag them, delete them, etc. It's obviously going to be used for that exact purpose, for scheduling employee hours. I don't need anything which is integrated with anything else, such as database, I can do all that work myself. I just want a simple control that can be used for visually creating such a schedule.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Visual Plan-It 听起来可能符合要求。它是 TurboPower Software 的旧组件库之一,他们在退出 VCL 业务时非常愿意将其开源。
您没有提到 Delphi 的版本,但据我所知,上述内容适用于 Delphi 7 之前的所有版本。如果您稍微搜索一下,您也许可以找到 D2009 及更高版本(支持 Unicode)的更新版本。
编辑:查看 Visual Plan-It 后,您似乎只需进行一些更改即可使其在 XE2 下编译。如果您打开 Delphi 7 包 (v103_d7.dpk),然后从
Project Manager
上下文菜单中选择Install
,您将在许多包含指针取消引用的行上收到错误运算符 (^
) 如List^
中所示;只需删除保留成员名称的运算符,如List
中所示。其余错误与对
inherited;
的无效调用有关(将其更改为inherited SetPointer(Ptr, Size);
来修复它,并调用LoadBitmap
抱怨不兼容的类型:PWideChar 和 PAnsiChar
- 这个只需要在参数传递时将LoadBitmap
更改为LoadBitmapA
调用它的函数被声明为接收PAnsiChar
参数。您还需要编写自己的
TVpCustomDataStore
后代(请参阅VpBaseDS.pas
)。 code>) 来处理数据存储;演示使用 BDE 或 Flex 数据库,因为我没有安装它们,所以无法给您屏幕截图,我可能在我的设备上安装了 D7 或 2007 的版本。办公室;我明天会检查,如果是的话更新我的答案。Visual Plan-It sounds like it might fit the bill. It's one of the old TurboPower Software component libraries they were nice enough to make open-source when they went out of the VCL business.
You didn't mention what version of Delphi, but AFAIK the above works with all versions of Delphi through 7. You may be able to find an updated version for D2009 and above (with Unicode support) if you search around a bit.
EDIT: After looking at Visual Plan-It, it appears there are only a few changes you have to make to get it to compile under XE2. If you open the Delphi 7 package (v103_d7.dpk) and then choose
Install
from theProject Manager
context menu, you'll get an error on many lines containing a pointer dereference operator (^
) as inList^
; simply remove the operator leaving the member name, as inList
.The remaining errors are related to an invalid call to
inherited;
(changing it toinherited SetPointer(Ptr, Size);
instead fixes it, and a call toLoadBitmap
that complains aboutincompatible types: PWideChar and PAnsiChar
- this one just requires changingLoadBitmap
toLoadBitmapA
, as the param passed to the function that calls it is declared as receiving aPAnsiChar
parameter.You'll also need to write your own descendent of
TVpCustomDataStore
(seeVpBaseDS.pas
) to handle data storage; the demos use a BDE or Flex database, and since I don't have either of them installed I can't give you a screen capture. I may have a version installed for D7 or 2007 at my office; I'll check tomorrow, and if so update my answer then.