App icon in UWP - xamarin

I am new to Xamarin and I am creating UWP application. I wanted to know From where i can set app icon image. I had gone through may articles and question on stack-overflow that looks similar, but it still its not clear..
So my Question is exactly where i should change my image for logo. only 24x24 as shown in below image.then what are the others badge logo and etc.?
should i change all images for logo with all dimensions also?
AppxMainfest.Xaml
<?xml version="1.0" encoding="utf-8"?>
<Package ...>
...
<Properties>
<DisplayName>StockDispatchApp.UWP</DisplayName>
<PublisherDisplayName>pci207</PublisherDisplayName>
<Logo>Assets\StoreLogo.png</Logo>
</Properties>
<Dependencies>
<TargetDeviceFamily Name="Windows.Universal" MinVersion="10.0.10240.0" MaxVersionTested="10.0.10586.0" />
</Dependencies>
<Resources>
<Resource Language="EN-US" />
</Resources>
<Applications>
<Application Id="App" Executable="StockDispatchApp.UWP.exe" EntryPoint="StockDispatchApp.UWP.App">
<uap:VisualElements DisplayName="StockDispatchApp.UWP" Square150x150Logo="Assets\Square150x150Logo.png" Square44x44Logo="Assets\Square44x44Logo.png" Description="StockDispatchApp.UWP" BackgroundColor="transparent">
<uap:LockScreen Notification="" BadgeLogo="Assets\96x96.png" />
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png"></uap:DefaultTile>
<uap:SplashScreen Image="Assets\SplashScreen.png" />
</uap:VisualElements>
</Application>
</Applications>
<Capabilities>
<Capability Name="internetClient" />
</Capabilities>
...

The MSDN documentation provides clear description of where each of the images is used. In the bottom you can see Asset size tables tables which contain all the dimensions and their usage.
As for the Square 44x44 logo, the first five images in the first row are used for different scales in the app list.
The target images are used for app icons in different places around the system. In their unplated form, they should have transparent background. You can provide just the sizes recommended by the form, but you can also provide more sizes (see the documentation for the complete table).

You don't need to worry about this, you can simply generate all the icons from Visual Studio 2017.
Go to App manifest and click on Visual Assets In all visual assets
There is option called Asset Generator, select at least a 400x400 px
icon file size for the source field
And tap generate And here you get
the all icons.
For reference please have a look at the attached screenshot.

Related

Is there a way how to hide quick find on top of grid?

Is there a way to hide quick find search box on top of grid - either programmatically or via ribbon / customizations ? Btw, it should be in supported/able manner (no direct DOM manipulations).
If anyone is interested - it is possible; it involves a shipping of your own custom grid control. Then in control manifest make sure to specify
cds-data-set-options="displayViewSelector:false;displayQuickFind:false"
<?xml version="1.0" encoding="utf-8"?>
<manifest>
<control namespace="MyControls.MyGridControl" constructor="MyGridControl" display-name-key="MyGridControl" description-key="MyGridControl" version="1.0.0" hidden="false" control-type="virtual">
<modes><read /><edit /></modes>
<data-set name="Grid" display-name-key="CC_Grid_DSGrid" cds-data-set-options="displayViewSelector:false;displayQuickFind:false"></data-set>
<dependencies>
<dependency name="MscrmControls.Grid.ReadOnlyGrid" />
</dependencies>
<resources>
<code path="MyGridControl.js" order="1" />
</resources>
<AvailableOn>
<web classic="enable" />
<phone />
<tablet />
</AvailableOn>
</control>
</manifest>
Unfortunately they are core platform functionalities and uncustomizable, and your necessity to turn off that capability is not an usual one. So it is not possible in any supported way today.
Maybe you can create an idea, if community voted for it - Microsoft may give that configuration in future releases.

UWP console app with no icon, just execution alias

I have an Win32 application ported to UWP using desktop bridge.
The application has both GUI and command-line interface (separate executables).
I'd like to have an icon and execution alias for the GUI interface, but only execution alias for the command-line interface. I do not want to pollute the Start menu with an icon no one will ever use.
For that I've understood that the manifest needs to include two Application elements, one for the GUI and one for the command-line interface, as one Application can include only one AppExecutionAlias.
See also Create a Universal Windows Platform console app.
My idea was something like this:
<Applications>
<!-- GUI -->
<Application Id="MyApp" Executable="MyApp.exe" EntryPoint="Windows.FullTrustApplication">
<!-- with icon -->
<uap:VisualElements DisplayName="MyApp" Description="MyApp" ...>
...
</uap:VisualElements>
<!-- and execution alias -->
<Extensions>
<uap5:Extension Category="windows.appExecutionAlias"
Executable="MyApp.exe" EntryPoint="Windows.FullTrustApplication">
<uap5:AppExecutionAlias>
<uap5:ExecutionAlias Alias="MyApp.exe" />
</uap5:AppExecutionAlias>
</uap5:Extension>
</Extensions>
</Application>
<!-- Command-line interface -->
<Application Id="MyApp-commandline" Executable="MyApp-commandline.exe"
EntryPoint="Windows.FullTrustApplication">
<!-- with execution alias only -->
<Extensions>
<uap5:Extension Category="windows.appExecutionAlias"
Executable="MyApp-commandline.exe" EntryPoint="Windows.FullTrustApplication">
<uap5:AppExecutionAlias>
<uap5:ExecutionAlias Alias="MyApp-commandline.exe" />
</uap5:AppExecutionAlias>
</uap5:Extension>
</Extensions>
</Application>
</Applications>
But I cannot find out how (if even possible) to have Application with no icon, as it seems that the VisualElements part is mandatory. So the above manifest is invalid. Of it there's some trick to an additional another execution alias (for a different binary) to the (first and only) Application.
Yes, the VisualElements part is mandatory as the file warned, we should follow the rules that the .Manifest file required. But if you don't want to have some Icons, you can try to provide a URI that doesn't refer a real image resource. Such as,
<uap:VisualElements
DisplayName="ConsoleUWP"
Square150x150Logo="Square150x150Logo.png"
Square44x44Logo="Image.png"
Description="ConsoleUWP"
BackgroundColor="transparent">
<uap:DefaultTile Wide310x150Logo="Image.png"/>
<uap:SplashScreen Image="Assets\SplashScreen.png" />
</uap:VisualElements>
the Square44x44Logo, Square150x150Logo and Wide310x150Logo don't refer to correct URIs for images, but the uap:SplashScreen can not be configure a wrong URI, if you did that, it would get error.
---Update---
We can use the Applications element to specify one or more apps for the package, but every Application need the VisualElements part in the UWP .manefest file. So if you add another , you will need to add the Visual Elements as it required, your idea can not implement. Also note that although each package can contain one or more apps, packages that contain multiple apps won't pass the Store certification process, that is to say you can not publish to store.
On the other hand, you can try to create a package that includes both a Win32 and Universal Windows Platform (UWP) processes, and communicate between them via an AppService APIs. It use the FullTrustProcessLauncher extension but not another . You can try and see the sample:
https://github.com/Microsoft/DesktopBridgeToUWP-Samples/tree/master/Samples/AppServiceBridgeSample

How to show application name in windows tiles in windows phone uwp

How to show the application name in the tiles.
As shown in the figure, i am developing the last application in the screen. For that i need to show the name of the application.
In PackageManifest file i have added all the images to show the images in the home screen.
Any help on this highly appreciated.
Thank you.
<Applications>
<Application Id="App" Executable="$targetnametoken$.exe" EntryPoint="MMRevamp_2016.App">
<uap:VisualElements DisplayName="Maalaimalar" Square150x150Logo="Assets\Square150x150Logo.png" Square44x44Logo="Assets\Square44x44Logo.png" Description="MMRevamp_2016" BackgroundColor="transparent">
<uap:LockScreen Notification="badge" BadgeLogo="Images\BadgeLogo.png" />
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png" Square71x71Logo="Images\Square142x142Logo.png" Square310x310Logo="Images\Square310x310Logo.png">
<uap:ShowNameOnTiles>
<uap:ShowOn Tile="square310x310Logo" />
</uap:ShowNameOnTiles>
</uap:DefaultTile>
</uap:VisualElements>
</Applications>
If you open your Package.appxmanifest and go to Visual Assets, you will see show name with check boxes. Check off appropriate box next to your asset.
See Screenshot for Example
If you are doing XML you can set the branding attribute to "name" as well. E.g like this:
<tile>
<visual>
<binding template="TileMedium" branding="name">
</binding>
</visual>
</tile>

WiX Patch dialog - background image not shown

I have created an working WiX Patch but during it's installation it does not show the product background image.
The original product setup dialog shows the images and they are defined in it's project like:
<Product ...>
<WixVariable Id="WixUIBannerBmp" Value="gn_setup_dialog_banner.bmp" />
<WixVariable Id="WixUIDialogBmp" Value="gn_setup_dialog.bmp" />
The patch is created and works fine. The problem is that it does not show these images. It shows some default background for the dialog.
Here is my patch if this helps:
<?xml version='1.0' encoding='windows-1252'?>
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
<Patch AllowRemoval='yes'
Manufacturer='xxx'
MoreInfoURL='...'
DisplayName='...'
Description='Small Update Patch'
Classification='Update'
Codepage="...">
<Media Id='5000' Cabinet='RTM.cab'>
<PatchBaseline Id='RTM' />
</Media>
<PatchFamily Id="HotFixPatchFamily" Version="1.0.1.0" Supersede="no" />
</Patch>
</Wix>
Thanks for helping.
For some reason the patch was delivering these two files as "new" ones...even tough they were not changed.
Anyway, I solved the problem by replacing the stock Wix dialog images, like it is suggested here (at bottom "Replacing the stock bitmaps"):
http://wix.sourceforge.net/manual-wix2/WixUI_dialog_library.htm

how can i add a new icon to a Visual Studio 2010 extension?

i'm developing a Visual Studio 2010 extension, i already have a toolbar inside my window. on that toolbar i have a button that i want to give an icon - my own icon!
I've read this article and it is great but... it explains how to replace the icons.
i want to add an additional icon.
how do i achieve that?
First, add the bitmap and set its build action to Resource
Remember, shocking pink = transparent (damn you, old school!)
Then, in your vsct file, add the image to the bitmaps section
<Bitmaps>
<Bitmap guid="AddSampleData.bmpGuid"
href="..\Button Bitmaps\AddSampleData.bmp"
usedList="AddSampleData.bmpId" />
<Bitmap guid="ApplySampleData.bmpGuid"
href="..\Button Bitmaps\ApplySampleData.bmp"
usedList="ApplySampleData.bmpId" />
</Bitmaps>
and assign it a guid in the symbols node
<Symbols>
<!-- snip -->
<GuidSymbol name="AddSampleData.bmpGuid"
value="{dcae7c84-8e91-4f8a-907b-95ccb0f52e6e}">
<IDSymbol name="AddSampleData.bmpId"
value="1" />
</GuidSymbol>
<GuidSymbol name="ApplySampleData.bmpGuid"
value="{9f555245-2430-4e6f-992b-b49ce87a31a2}">
<IDSymbol name="ApplySampleData.bmpId"
value="1" />
</GuidSymbol>
</Symbols>
and apply it to a button
<Buttons>
<!-- snip -->
<Button guid="guidEditorExtensionCommandSet"
id="setDesignTimeDataOnPage"
priority="0x0100">
<Icon guid="ApplySampleData.bmpGuid"
id="ApplySampleData.bmpId" />
<Strings>
<!-- snip -->
</Strings>
</Button>
</Buttons>
Of course, its always easier to use the available tools, including the excellent VSPackage Builder extension.
A workaround for this is to create a PNG and rename the extension as *.bmp. VS will accept it as an icon image and it will also have transparency (from Visual Studio Extensibility > Toolbox Icons -- Is transparency supported?)

Resources