I have two WIX dialogs in my setup project
Final form which is to be shown when installer terminates with status 'success'
<Dialog Id="FinishedForm">
...
</Dialog>
and page to show several slides about our Product.
<Dialog Id="IntroductionTourPage">
...
<Control Id="SkipTourButton" Type="PushButton">
<Publish Event="NewDialog" Value="FinishedForm">1</Publish>
</Control>
...
</Dialog>
I want IntroductionTourPage is only to be shown after product is installed(not upgraded or removed), but I do not know how to do that. I tried
<InstallUISequence>
<Show Dialog="FinishedForm" OnExit="success">Condition</Show>
<Show Dialog="IntroductionTourPage" OnExit="success">NOT Condition</Show>
</InstallUISequence>
but it is not valid in Wix so it this approach failed. Then I tried
<InstallUISequence>
<Show Dialog="FinishedForm" Sequence="1">Condition</Show>
<Show Dialog="IntroductionTourPage" Sequence="2">NOT Condition</Show>
</InstallUISequence>
it didn't work. I tried then
<InstallUISequence>
<Show Dialog="FinishedForm" OnExit="success"/>
<Show Dialog="IntroductionTourPage" Before="FinishedForm">Condition</Show>
</InstallUISequence>
but it is not valid in Wix as well.
Now I want to try smth like:
<InstallUISequence>
<Custom Action="CA_ChooseAndShowDialogBasedOnCondition" OnExit="success"/>
</InstallUISequence>
but I can't find any example how to show Wix dialogs from CA.
Any ideas?
Thanks in advance,
Andriy
I have something different solution for you. Try this if you found this is suitable for your requirement.
Add all controls in your FinishedForm to IntroductionTourPage. Use IntroductionTourPage as the Success exit dialog. Display the controls in IntroductionTourPage dialog based on the condition.
Now IntroductionTourPage will act as both FinishedForm and IntroductionTourPage as per the condition. You can use FinishedForm dialog from IntroductionTourPage if required.
Example: Title Control in IntroductionTourPage
<Control Id="Title" Type="Text" X="188" Y="22" Width="330" Height="22" Transparent="yes" NoPrefix="yes" Text="Welcome to the IntroductionTourPage" >
<Condition Action="hide">Condition</Condition>
</Control>
<Control Id="FinishTitle" Type="Text" X="188" Y="15" Width="316" Height="22" Transparent="yes" NoPrefix="yes" Text="Completed the Sample Setup Wizard" Hidden="yes">
<Condition Action="show">Condition</Condition>
</Control>
Related
Screenshot of ribbon of web outlook without add-in label, just icon :
On the web version of outlook, the add-in icon shows without it's label. I would like to have the label appear beside the add-in icon. The desktop version of outlook works fine. The tooltip on for the add-in icon (web version) shows the DisplayName - Description, but again I need help setting up the manifest to show the label beside the icon for the web version of outlook. Thanks!!!
and here is part(s) of the manifest (patterned after the manifest on https://github.com/OfficeDev/Office-Addin-TaskPane/blob/master/manifest.xml
<DisplayName DefaultValue="Event Details" />
<Control xsi:type="Button" id="appointmentOpenPaneButton">
<Label resid="paneAppointmentButtonLabel" />
<Supertip>
<Title resid="paneAppointmentSuperTipTitle" />
<Description resid="paneAppointmentSuperTipDesc" />
</Supertip>
<Icon>
<bt:Image size="16" resid="icon16" />
<bt:Image size="32" resid="icon32" />
<bt:Image size="80" resid="icon80" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="appointmentEditTaskPaneUrl" />
</Action>
</Control>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="Temp Group Name" />
<bt:String id="paneAppointmentButtonLabel" DefaultValue="Temp Button Label" />
<bt:String id="paneAppointmentSuperTipTitle" DefaultValue="Set Event details" />
</bt:ShortStrings>
Unfortunately, there's no way to show the button label beside the icon, this is by design. If this is a design requirement for you, please reach out on our Tech Community page: aka.ms/M365dev-suggestions
Creating a custom dialog with WiX Toolset 3.8., I struggled to enable the close button of the dialog, and while I found some hints on the web, there was no clean answer anywhere. Adding this question for the sake of the next person to have the same problem.
you also need the "EndDialog" event with the "Return" value
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Default="yes" Text="Cancel" Cancel="yes" >
<Publish Event="EndDialog" Value="Return">1</Publish>
</Control>
The dialog needs to contain a control with Cancel="yes", this seems to be tied to the enabled state of the window close button.
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Default="yes" Text="Cancel" Cancel="yes" />
I tried to add a button to connection subgrid ribbon. This button should only be visible if the primary entity equals 'new_visitreport'.
Here is my try:
<CustomAction Id="Visitreports.connection.customAction"
Location="Mscrm.SubGrid.connection.MainTab.Management.Controls._children"
Sequence="15" >
<CommandUIDefinition>
<Button Id="Mscrm.SubGrid.connection.AddXYZ"
ToolTipTitle="$LocLabels:Button.AddXYZ.Label"
ToolTipDescription="$LocLabels:Button.AddXYZ.Tooltip"
LabelText="$LocLabels:Button.AddXYZ.Label"
Command="Button.AddXYZ.Command"
Image16by16="$webresource:new_XYZ_16"
Image32by32="$webresource:new_XYZ_32"
TemplateAlias="o1" />
</CommandUIDefinition>
</CustomAction>
<CommandDefinition Id="Button.AddXYZ.Command">
<EnableRules></EnableRules>
<DisplayRules>
<DisplayRule Id="EntityEqualsVisitreport" />
</DisplayRules>
<Actions>
<JavaScriptFunction FunctionName="openDialog"
Library="$webresource:new_script_open_dialog">
<StringParameter Value="3EEE3AE1-5543-433E-8123-6A14EA925A96" />
<StringParameter Value="3EEE3AE1-5543-433E-8123-6A14EA925A96" />
<BoolParameter Value="false" />
</JavaScriptFunction>
</Actions>
</CommandDefinition>
<DisplayRule Id="EntityEqualsVisitreport">
<EntityRule AppliesTo="PrimaryEntity"
EntityName="new_visitreport" />
</DisplayRule>
It seems that this rule always returns false. If I remove the display rule from command definition the button is visible, but independet of the currently primary entity.
Is there any mistake in my examply or is it not working for custom entitis although it is supported? (MSDN article)
Try using FormEntityContextRule it looks like these guys had the same issue you had. Forum Link
<FormEntityContextRule EntityName="account"/>
How can I add a menu and sub menu items when right click on a file item visual studio solution explorer?
I have one menu and three sub menu items which will be displayed when I right click on a file in solution explorer like the below picture.
I tried using .vsct buttons but it will display on context menu and Iam unable to add sub menus
Authoring VSCT files is somewhat tricky; what you´ll need is a combination of a menu and buttons. First of all you need to reference the IDM_VS_CTXT_ITEMNODE group in your VSCT file.
<Group guid="guidCmdSet" id="grpIdMenuProjectItem" priority="0x0800">
<Parent guid="guidSHLMainMenu" id="IDM_VS_CTXT_ITEMNODE" />
</Group>
Than you create a new menu and add it to that group...
<Menu guid="guidCmdSet" id="sampleMenu" type="Menu" priority="0x1000">
<Parent guid="guidCmdSet" id="grpIdMenuProjectItem" />
<CommandFlag>IconAndText</CommandFlag>
<Strings>
<ButtonText>Sample Menu</ButtonText>
<CommandName>Sample Menu</CommandName>
</Strings>
</Menu>
For the submenu items another group is required, which will be added to the menu...
<Group guid="guidCmdSet" id="sampleMenuGroup" priority="0x1000">
<Parent guid="guidCmdSet" id="sampleMenu"/>
</Group>
At least you define your submenu items using buttons and add them to the submenu group...
<Button guid="guidCmdSet" id="sampleMenuItem" priority="0x1000" type="Button">
<Parent guid="guidCmdSet" id="sampleMenuGroup"/>
<CommandFlag>TextOnly</CommandFlag>
<Strings>
<ButtonText>Sample Menu Item 1</ButtonText>
<CommandName>sampleMenuItem1</CommandName>
</Strings>
</Button>
Don´t forget to define all symbols, otherwise the resource won´t compile.
<IDSymbol name="grpIdMenuProjectItem" value="0x1020"/>
<IDSymbol name="sampleMenu" value="0x1021"/>
<IDSymbol name="sampleMenuGroup" value="0x1022"/>
<IDSymbol name="sampleMenuItem" value="0x1023"/>
And this is what you get...
I found a lot of examples how to add custom tab with custom controls on the ribbon bar. But no one works for me. I got the custom tab, but button is always disabled.
There is my current version of code:
<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<CustomAction
Id="CustomRibbonTab"
Location="CommandUI.Ribbon"
RegistrationId="101"
RegistrationType="List">
<CommandUIExtension>
<CommandUIDefinitions>
<CommandUIDefinition
Location="Ribbon.Tabs._children">
<Tab
Id="Ribbon.CustomTab"
Title="Custom Tab"
Description="Custom Tab !!!"
Sequence="701">
<Scaling
Id="Ribbon.CustomTab.Scaling">
<MaxSize
Id="Ribbon.CustomTab.MaxSize"
GroupId="Ribbon.CustomTab.CustomGroup"
Size="OneLargeTwoMedium"/>
<Scale
Id="Ribbon.CustomTab.Scaling.CustomTabScaling"
GroupId="Ribbon.CustomTab.CustomGroup"
Size="OneLargeTwoMedium" />
</Scaling>
<Groups Id="Ribbon.CustomTab.Groups">
<Group
Id="Ribbon.CustomTab.CustomGroup"
Description="Custom Group!"
Title="Custom Group"
Sequence="62"
Template="Ribbon.Templates.CustomTemplate">
<Controls Id="Ribbon.CustomTab.CustomGroup.Controls">
<Button
Id="Ribbon.CustomTab.CustomGroup.CustomButton"
Command="CustomTab.CustomButtonCommand"
Sequence="115"
Description=""
LabelText="Custom Button"
Image32by32="/_layouts/images/PPEOPLE.GIF"
TemplateAlias="cust1"/>
</Controls>
</Group>
</Groups>
</Tab>
</CommandUIDefinition>
<CommandUIDefinition Location="Ribbon.Templates._children">
<GroupTemplate Id="Ribbon.Templates.CustomTemplate">
<Layout
Title="OneLargeTwoMedium"
LayoutTitle="OneLargeTwoMedium">
<Section Alignment="Top" Type="OneRow">
<Row>
<ControlRef DisplayMode="Large" TemplateAlias="cust1" />
</Row>
</Section>
</Layout>
</GroupTemplate>
</CommandUIDefinition>
</CommandUIDefinitions>
<CommandUIHandlers>
<CommandUIHandler
Command="CustomTab.CustomButtonCommand"
CommandAction="javascript:alert('Hello, world!');"
EnabledScript="javascript:return true;"/>
</CommandUIHandlers>
</CommandUIExtension>
</CustomAction>
</Elements>
I cleaned up the cache. I read about importance of EnabledScripts attribute in the CommandUIHandler. But I always have the same result:
Did anybody have the same issue? Please help!
I checked out a local custom action of mine, and the EnabledScript followed a different pattern:
EnabledScript="javascript:function JustReturnTrue()
{
return true
}
JustReturnTrue();"
If your item is showing up, but always disabled, I bet that's where the problem is.
I think the attribute is optional anyway, if I recall.
I had the same problem, I'm not sure if this is the proper solution, I'm a newbie. I removed the element from feature which scope was set to "Site", added another feature, set the scope to "Web", added my button item in this feature, saved, deployed, enabled the new feature from site features and it worked.