Ms Excel下拉框 [英] Ms Excel drop down box

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

问题描述




有谁能告诉我如何在Excel女士中创建一个下拉框。


我简单一个可以它有一些价值。


希望你理解..我不确定下拉菜单/框和组合框之间有什么区别。但它以ms excel重新获得。


谢谢

user__786

Hi

Can anyone tell me how to create a drop-down box in Ms Excel please.

I simple one which can have in it some values.

Hope you understand.. i am not sure what is the difference between drop-down menu/box and combo box. but it is reuqired in ms excel.

thanks
user__786

推荐答案


您好


有人可以告诉我如何在Excel中创建一个下拉框。


我很简单,可以有一些值。


希望你理解..我不确定下拉菜单/框和组合框之间有什么区别。但它以ms excel的形式重新获得。


感谢

user__786
Hi

Can anyone tell me how to create a drop-down box in Ms Excel please.

I simple one which can have in it some values.

Hope you understand.. i am not sure what is the difference between drop-down menu/box and combo box. but it is reuqired in ms excel.

thanks
user__786

在Excel工作表中:
__ 1。查看==>工具栏==>控制工具箱
__ 2。在工作表上选择并绘制组合框
__ 3。 ALT + F11转到Visual Basic窗口
__ 4。在Worksheet_Activate()事件中放置以下代码

Within your Excel Worksheet:
__1. View ==> Toolbars ==> Control Toolbox
__2. Select and Draw a Combo Box on the Worksheet
__3. ALT+F11 to go to the Visual Basic Window
__4. In the Worksheet_Activate() Event place the following code

展开 | 选择 | Wrap | 行号


如果使用文本验证功能,它可能会更好。然后你的用户可以选择实际的单元格,并从列表中选择。


这样做:



某些地方在用户不太可能找到它的工作表上输入您希望他们使用的选项。请务必留空单元格,或使用从列表中选择。在那个单元格中,你没有默认值是实际值。


现在,
  • 点击数据 菜单栏
  • 点击验证...

    向导将打开
  • 选择在设置标签
  • 允许下拉列表中选择列表
  • 到右侧2将出现新框 - 如果您在列表中使用了空白,请选择忽略空白
  • 单击源框末尾的按钮,以便您可以选择之前输入的数据列表。请务必选择空白单元格或从列表中选择。
It might work better if you use the text validation feature. Then your user can select on the actual cell, and choose from a list.

to do this:


some where on the sheet where the user is unlikely to find it enter the options you want them to use. Be sure to either leave a blank cell, or use "select from list" in that cell so you don''t have a default value that is an actual value.

Now,
  • click on Data in the Menu Bar
  • click on Validation...
    the wizard will open
  • Select In the Settings Tab
  • Select List from the Allow drop down
  • to the right 2 new boxes will appear - if you used a blank in your list de-slect ignore blanks
  • click the button at the end of the Source box, so you can select the list of data you entered earlier. Be sure to select the blank cell or select from list.


非常感谢Sophie和ADezii


ADezii ..

你的意思是:Worksheet_Activate()

当我按ALT + F11时,我转到VB代码编辑器。我可以看到我的Ms Excel Worksbook上的可用工作表。我选择了我目前正在处理的工作表。


例如,这就是我在条形图上看到的:

Book1.xls - Sheet1(代码)


我已经尝试过你的方法,当我回到Excel并退出设计模式时,我在组合框中看不到任何值。


任何想法!!


谢谢
Thanks Sophie very much and ADezii


ADezii ..
What you mean by : Worksheet_Activate()

When i press ALT+ F11 i goto VB code editor. I can see available sheets that i have on my Ms Excel Worksbook. I selct the sheet that i am currently working on.

For example, this is what i see on bar on top:
Book1.xls - Sheet1 (Code)

I have tried exacly with your method, when i come back to Excel and go out of Design mode, i see no Values in the Combo Box.

any ideas !!

Thanks


这篇关于Ms Excel下拉框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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