【发布时间】:2019-04-04 01:32:58
【问题描述】:
我正在使用 VSTO 插件添加一个可能对我有用的功能。 所以到目前为止我所做的就是将我的ribbon.xml 声明如下:
<tabs>
<tab idMso="TabAppointment" insertAfterMso="TabAddIns">
<group id="TripGroup" label="Add Trip">
<dropDown id="TripBooking_Tab_AddMeetingBefore"
getLabel="GetLabel"
getSelectedItemIndex="TripBooking_Tab_AddMeeting_GetSelectedItemIndex"
getItemCount="TripBooking_Tab_AddMeeting_GetItemCount"
getItemID="TripBooking_Tab_AddMeeting_GetItemID"
getItemLabel="TripBooking_Tab_AddMeeting_GetItemLabel"
onAction="TripBooking_Tab_AddMeetingBefore_OnAction"/>
<separator/>
<dropDown id="TripBooking_Tab_AddMeetingAfter"
getLabel="GetLabel"
getSelectedItemIndex="TripBooking_Tab_AddMeeting_GetSelectedItemIndex"
getItemCount="TripBooking_Tab_AddMeeting_GetItemCount"
getItemID="TripBooking_Tab_AddMeeting_GetItemID"
getItemLabel="TripBooking_Tab_AddMeeting_GetItemLabel"
onAction="TripBooking_Tab_AddMeetingAfter_OnAction"/>
</group>
</tab>
</tabs>
一切都像一个魅力,我在 UI 中得到了我的 2 dropdown。
现在的问题是:我如何为每个新约会检索dropdown 的值?
【问题讨论】:
-
如果你贴出
getSelectedItemIndex、getItemCount、getItemID和getItemLabel的过程,我可以举一个更详细的例子。
标签: c# vsto outlook-addin add-in