Excel VBA:搜索问题 [英] Excel VBA: Search Problems

查看:72
本文介绍了Excel VBA:搜索问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经发布了这个问题(管理员编辑需要帮助我的搜索宏for excel ),但我在写这个问题时犯了一个错误,所以我发布了一个回复,我担心一眼就可以看作是回答。因此,我正确地重新提出我的问题,因为我迫切需要帮助!我的老板需要这个,我试图操纵在这个网站上给我的代码,但我不熟悉宏。我的问题是如何搜索多列数据。我在B列中有一个月,在C列中有一年,在D列中有一个人的名字。下面我已经包含了我搜索一列的搜索宏,但我需要能够搜索所有三个列。我知道如何制作三个输入框来输入我正在搜索的信息,但我不知道如何操作此代码来搜索多个列。拜托,拜托,请帮助我,因为我要疯狂地努力解决这个问题。非常感谢你!

I posted this question already (Admin Edit Need help with my search macro for excel), but I made a mistake in writing the question, so I posted a reply and I am afraid that at a glance it may be viewed as answered. Therefore, I am reposting my question correctly because I desperately need help! My boss needs this and I have tried to manipulate a code that was given to me on this site, but I am not versed in macros. My question is how to search multiple columns of data. I have a month in column B, a year in column C, and a person''s name in column D. Below I have included the search macro I have that searches the one column, but I need to be able to search all three columns. I know how to make three input boxes to put the information in that I am searching for, but I don''t know how to manipulate this code to search more than one column. Please, please, please help me with this because I am about to go crazy struggling to figure this out. Thank you so much in advance!

展开 | 选择 | Wrap | 行号

推荐答案

如果您可以按照我在示例中使用的方式发布表格的元数据(有关布局/结构的信息)。单击回复按钮,您将可以访问我使用过的所有代码。 PK& FK代表Primary Key&外键分别为。
表名= [ tblStudent ]
This will work much better if you can post the meta-data (info about the layout / structure) of the table in the same way as I use in my example. Click on the Reply button and you will have access to all the codes I''ve used. PK & FK stand for Primary Key & Foreign Key respectively.
Table Name=[tblStudent]
展开 | 选择 | 换行 | 行号


好吧,你可以抓住所有这些,因为我现在发现MS Access / VBA论坛中的这个问题实际上是一个Excel问题。


让我重命名线程对于更有意义的事情,我可能会有另一种看法。
Well, you can probably scratch all that as I now find that this question in the MS Access / VBA forum is actually an Excel question.

Let me rename the thread to something that makes better sense then I may have another look.


对,现在我们都明白你在谈论Excel问题......

你需要解释你想要达到的目标比你好多了。


请提供一些你希望如何工作的例子。你会单独输入搜索项吗?如果没有,你设想什么?
Right, now we all understand that you''re talking about an Excel issue...

You need to explain what you''re trying to achieve a lot better than you have.

Please provide a few examples of how you expect this to work. Would you enter the search items separately? If not, what do you envisage?


这篇关于Excel VBA:搜索问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆