c#DevExpress PopupMenu动态填充项目

时间:2017-03-30 07:17:18

标签: c# devexpress popupmenu

我试图动态填充DevExpress PopuMenu项目,但是,它只显示Items(BarButtonItem),而不显示Groups(BarLinkContainerItem):

Sub ExportToPDF()
    Dim file_path As String
    Dim search_range As String
    Dim each_cell As Range
    Dim rng1 As Range
    ' Set search_range as desired search range
    search_range = ActiveSheet.Range("A53:R56")


    Set rng1 = ActiveSheet.Range("A53:R56").Find("ProductX", , xlFormulas, xlPart)
    If Not rng1 Is Nothing Then
        file_path = Some_path_A
    Else
        file_path = Some_path_B
    End If

    'Export the sheet as PDF
    ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:=file_path, Quality:=xlQualityStandard _
            , IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:= _
            True
End Sub

我想显示按钮的弹出菜单Onclick事件:As you see only Items are displayed, group is not added. Action2 in fact must be added to Group1

感谢。

0 个答案:

没有答案