显示标签控件中的最后一个单词 [英] Displaying last words in a label control

查看:77
本文介绍了显示标签控件中的最后一个单词的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

语言:C#/ WPF,VS2012,带标签的WPF窗口

我有一个位于WPF窗口中的图像控件内的标签。标签显示文件的文件路径。我的问题是我似乎无法找到最后几个字的方法,即显示文件名和扩展名。我已经尝试将Horizo​​ntalContentAlignment设置为Right,但这没有帮助。

Language: C#/WPF, VS2012, WPF Window with label
I have a label that sits inside of an image control in a WPF window. The label displays the file path for a file. My problem is that I can't seem to find a way to get the last few words, ie filename and extension to be displayed. I've tried setting HorizontalContentAlignment to Right, but that doesn't help.

推荐答案

你是什么意思得到最后几个字?



bryce
what do you mean by "get the last few words" ?

bryce


这篇关于显示标签控件中的最后一个单词的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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