如何在组合框中加载本地系统路径 [英] how to load local system path in combo box

查看:94
本文介绍了如何在组合框中加载本地系统路径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好



当我运行我的项目时,我正在创建一个文件夹到C:\驱动器中的特定位置。

(C:\ Application \Foldername)

现在我想把这条路径加载到我的组合框中。



请告诉我怎么做

Hi all

When i am running my project i am creating a folder to a particular location in C:\ drive.
(C:\Application\Foldername)
Now i want to load this path to my combo box.

Please tell me how to do that

推荐答案

这个微软文档提供了几种方法来实现这一点......无论是代码隐藏还是xaml

http://msdn.microsoft.com/en-us/ library / system.windows.controls.itemscontrol.items.aspx [ ^ ]
This microsoft documentation suggests a couple of ways of achieving this ... either in the code-behind or the xaml
http://msdn.microsoft.com/en-us/library/system.windows.controls.itemscontrol.items.aspx[^]


您提供的用于创建目录的字符串将相同的字符串添加到组合框

the string which you are providing to create directory add that same string to combobox
Combobox1.items.add("You Path Here")


这篇关于如何在组合框中加载本地系统路径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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