0

多年来,我一直在潜伏阅读各种主题。专业上,我是一名系统接口专家/接口架构师。我可以使用 tcl、Cloverleaf、HL7 甚至 Excel 创造奇迹,但 Microsoft Access 让我望而却步。它一再让我困惑和困惑。对我来说似乎简单和合乎逻辑的一切都不是 MS Access 所关心的。

所以,我来找你了。老实说,我什至不确定我能否用正确的“技术”词表达我想做的事情。我只知道完成后我希望事情如何运作。

我已经建立了一个非常“简单”的关系数据库,供收集句子或句子片段以供写作使用/启发的作者使用。共有三个表:

  • tblPhrases包含一个自动编号字段idxPhrases和一个备注字段Phrase
  • tblTags包含一个自动编号字段idxTags和一个备注字段Tag
  • tblTagsToPhrases包含一个自动编号字段idxTagsToPhrases和两个数字字段:Tags_indexPhrases_index

前两个表要求所有字段都是唯一的。

显然(或者不是?),第三个表是多对多连接。它允许有许多标签与一个短语相关联,并且多个短语与任何一个标签相关联。

我已经想出了如何设置表单和子表单,但是您可以看到它看起来很笨重,而且完全不是我想象的那样。 截屏

我真正想要的不是关键字/标签子表单中的下拉组合框——它确实从 tblTags 填充,当我选择某些内容时,正确填充 tblTagsToPhrases 并且当我在表单中返回该短语时,显示关联标签的列表。 ..

相反,我真正想要的是让 tblTags 中的值出现在网页上的“标签云”中​​。然后我可以单击该值的超文本控件,它将填充一个文本字段,在选择之间添加逗号。然而,在幕后,它实际上只是添加到 tblTagsToPhrases。我也应该可以在那里输入一个新的标签。基本上,将字段视为书签站点上的标记字段。

如果我真的诚实,我也希望能够将短语显示为超文本,因为这样看起来不那么笨重,也不像数据库。

任何人都可以给出一些方向,从我所在的地方到那里。

非常感谢您的任何帮助!

4

1 回答 1

0

You need VBA to do this, using the Timer event of the form to move labels around randomly, using some detailed maths to get them to move in a direction-of-flow, rather than completely random. Each label (or textbox) would first have to be populated with the field-values. If you only want a static tag-cloud then you wouldn't need the the Timer event.

If you don't know VBA then you'll have to search but I think it unlikely that you will find an example of this (and if you do, will you be able to adapt it?). In fact, if you get this to work, and include the animation, I would expect it to exhibit noticeable flicker.

I think you should ask yourself if you intend to build a database or a web-application. (If you are struggling with Access, why go even further and attempt to make it do things that it wasn't designed for?)

于 2013-07-21T13:58:43.910 回答