在标签标题中插入月份和年份

insert month and year into a label caption

如何更改标题末尾当前月份和年份的格式。我曾尝试在工作表上使用一个单元格,然后将其格式化为 mmmm yy,但是当我告诉标题更新 user-form 初始化序列时,它以短日期格式出现。以下是目前的代码。

 MobilePricing.Label313.Caption = "Daisy Group Vodafone Mobile Pricing Tool " & _
 Worksheets("Calculator").Range("V2")

任何关于如何将日期格式更改为 mmmm yy 的建议将不胜感激。

谢谢

我假设 V2 持有一个日期值。

MobilePricing.Label313.Caption = "Daisy Group Vodafone Mobile Pricing Tool " & _
 Format(Worksheets("Calculator").Range("V2"),"mmmm yy")

我已经使用Format函数将日期转换成你想要的格式。