Results 1 to 1 of 1
2012-08-07, 19:37 #1
- Join Date
- Jun 2012
- Thanked 0 Times in 0 Posts
Error message when re-purposing ribbon controls
I am trying to “re-purpose” the buttons in the Controls group to insert content controls with pre-set properties. I have created macros to insert the custom controls, and they work. (In my example below, I’m repurposing the Date Picker Content Control.)
Here is the XML to customize the ribbon:
<command idMso="ContentControlDate" onAction="PIMSmacros.RibPIMSDateControl"/>
Here is the macro it calls:
Sub RibPIMSDateControl(control As IRibbonControl)
Selection.ParentContentControl.DefaultTextStyle = "Field Text"
Selection.ParentContentControl.DateDisplayFormat = "yyyy-MM-dd"
When I load the template and click the button to insert a Date control, I get the error: “Wrong number of arguments or invalid property assignment.”
What am I missing?
Thanks in advance for any help you can provide.