Blend paths vs build tool
In Blend I made a folder called Images. I place all my images in there and all my xaml reference Images/myimage.png.
When I run this through the Build Tool I get an error on the xaml saying:
Parsing Image.Source
Image 'Images/Images/myimage.png' not found.
Why is the BuildTool attaching another Images in the path? If I alter the xaml to not have Images in the path the Build Tool works but then of course Blend doesn't.
When I run this through the Build Tool I get an error on the xaml saying:
Parsing Image.Source
Image 'Images/Images/myimage.png' not found.
Why is the BuildTool attaching another Images in the path? If I alter the xaml to not have Images in the path the Build Tool works but then of course Blend doesn't.
-
-
sfernandez
Site Admin
- Posts: 2099
- Joined:
Re: Blend paths vs build tool
Could you please post the <Image Source="???"/> that Blend is generating?
And also the exact file structure (where the .csproj, the xaml file, and the image are placed).
Thanks.
And also the exact file structure (where the .csproj, the xaml file, and the image are placed).
Thanks.
Re: Blend paths vs build tool
I have ImageBrush's:
My Blend structure is just:
Visual Studio 2013->Projects->HUD->HUD->Images
Visual Studio 2013->Projects->HUD->HUD->bin
etc
Code: Select all
<Grid x:Name="MasterGrid" Margin="0,0,0,5">
<Grid.Resources>
<ImageBrush x:Key="rifle" ImageSource="items.png" Stretch="Fill" ViewboxUnits="Absolute" Viewbox="0,0,256,64"/>
<ImageBrush x:Key="water_bottle" ImageSource="items.png" Stretch="Fill" ViewboxUnits="Absolute" Viewbox="0,384,64,64"/>
</Grid.Resources>
My Blend structure is just:
Visual Studio 2013->Projects->HUD->HUD->Images
Visual Studio 2013->Projects->HUD->HUD->bin
etc
-
-
sfernandez
Site Admin
- Posts: 2099
- Joined:
Re: Blend paths vs build tool
Assuming you are working with 1.2 version, I tried the following sample:
HUD/HUD/test.xaml
With the image placed at HUD/HUD/Images/items.png.
And calling BuildTool as follows:
It builds the xaml correctly, and as I also specified the --deps option, it builds the image too.
Are you doing anything different?
HUD/HUD/test.xaml
Code: Select all
<Grid
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Grid x:Name="MasterGrid" Margin="0,0,0,5">
<Grid.Resources>
<ImageBrush x:Key="rifle" ImageSource="Images/items.png" Stretch="Fill"
ViewboxUnits="Absolute" Viewbox="0,0,256,64"/>
</Grid.Resources>
<Rectangle Width="256" Height="64" Fill="{StaticResource rifle}"/>
</Grid>
</Grid>
And calling BuildTool as follows:
Code: Select all
> NoesisGUI-SDK-win\Bin\Resource.BuildTool.exe HUD\HUD\test.xaml --outdir HUD\HUD\bin\NoesisGUI --deps
Are you doing anything different?
Who is online
Users browsing this forum: Google [Bot] and 2 guests