Hello, I'm still a beginner with programming but I'm on my way.

I retrieve weather data trough an internet link (xml) the data (condition) inside that xml is linked via data binding in a text block named "hulptextblok".

Now I would like to use the if statement on that textbox but I get the error saying that the is not found.

This is because the textbox control is located inside a data template.

I have beentrieng for over 2 days toget it to work but with no succes 
I just Hope that you can shed some light on this problem. :-)

Xaml:

Orientation="Horizontal" Height="99" > Height="100"> Width="100"> Width="*"> Text="{Binding Path=condition}" Grid.Column="1" Margin="10,75,10,0" Name="hulpBlock">
Xaml.cs:        
 

if (hulpBlock.Text == "Partly Cloudy") { weatherframe.Source = (ImageSource)new ImageSourceConverter().ConvertFromString("WeatherIcons/03.png"); }

So what want is that if the text that is recieved inside the textbox matches "Partly Cloudy" the image source to change to "WeatherIcons/03.png"