This project is read-only.

VB.NET tutorial example

Jan 4, 2010 at 8:26 AM


When I try to build this example, I have got an error:

Module Module1

    Sub Main()
        Dim wD As Animaonline.WeatherAPI.WeatherData = New Animaonline.WeatherAPI.WeatherData(Animaonline.WeatherAPI.LanguageCode.en_US, "Phoenix, AZ")
        Console.WriteLine("Condition:{0} Temperature:{1}°F {2}°C", wD.condition, wD.temp_f, wD.temp_c)
    End Sub

End Module

Type 'Animaonline.WeatherAPI.WeatherData' is not defined, and suggest to change it to Animaonline.Weather.GoogleWeatherAPI, Animaonline.Weather.Interfaces.IGoogleWeatherData or Animaonline.Weather.WeatherData.GoogleWeatherData.

How can I resolve this?

Thanks, and sorry for my English! I'm a Hungarian... :)

Jan 4, 2010 at 8:30 AM

Hi! The example you are trying to compile is written in an earlier version of awAPI ( BETA

We updated awAPI to

Unfortunately I didn't have time to update the documentation.

You can check out my blog @ ( for some examples of awAPI usage.

Thank you :)

And don't hesitate to ask, if you have any other questions :)


Jan 4, 2010 at 9:21 AM


It work wery well!

One more question...

Is there any way to download data in Hungarian language?

Like this:


Jan 4, 2010 at 10:22 AM

Take a look at LanguageCode.cs 

Try and add hu or hu_HU


Jan 4, 2010 at 1:26 PM

Unfortunately not works...

hu_HU is selectable now, but the received data is still in English.

Another thing... is this .dll compatible with Compact Framework 3.5?

I want to run it on PocketPC.

Jan 4, 2010 at 1:31 PM

You will have to take a closer look at the code which handles language code parsing...

The previous version of the api was compatible with Compact Framework , I'm not sure about , because the core was rewritten to utilize LINQ

Why don't you try to compile the api as a Windows Mobile Class Library?

Keep me updated!

Cheers! :)


Jan 5, 2010 at 1:06 PM


Now, the weather data is downloaded in Hungarian... :)


namespace Animaonline.Weather
    public static class Functions
        public static Uri GoogleWeatherFeedUrl(CultureInfo cultureInfo)
            switch (cultureInfo.TwoLetterISOLanguageName.ToUpper())
                case "RU":
                    return GoogleWeatherFeedUrl(LanguageCode.ru_RU);
                case "HU":
                    return GoogleWeatherFeedUrl(LanguageCode.hu_HU);
                    return GoogleWeatherFeedUrl((LanguageCode)(-1));

        public static Uri GoogleWeatherFeedUrl(LanguageCode languageCode)
            switch (languageCode)
                case LanguageCode.ru_RU:
                    return new Uri(@"");
                case LanguageCode.hu_HU:
                    return new Uri(@"");
                    return new Uri(@"");


namespace Animaonline.Globals
    #region Enums
    /// <summary>
    /// Language Codes
    /// </summary>
    public enum LanguageCode
        /// <summary>
        /// English US
        /// </summary>
        /// <summary>
        /// Hungarian HU
        /// </summary>


Jan 5, 2010 at 1:12 PM

Alright!! :D

Congrats :)

Jan 6, 2010 at 9:38 AM

Unfortunately the v2.5.0.0 not works on PPC...

I used the previous version, I rewrite it to support the Hungarian language. Its works, but Unicode characters are not supported.

I try to add a System.Text.Encoding.Unicode parameter to the StreamReader, but its generates an XML Reader error.

Data at root level is invalid. Line1, Position 1

I try the UTF8 encoding, but still no Unicode characters in data.


Jan 8, 2010 at 6:27 PM

Please forget my last reply! It use UTF7 Encoding.

Jan 8, 2010 at 7:24 PM

What error message do you get when you try to compile for PPC platform?

I will update the encoding to UTF7 in all later versions.

Thank you

Jan 10, 2010 at 2:35 PM

The fist error is in the Network.cs

WebClient is not a member of System.Net

Its OK because Windows Mobile uses the HttpWebRequest and HttpWebRespons.

simply delete those rows what WindowsMobileDownloader does not use?

Jan 10, 2010 at 2:39 PM

Alright! I know that... You have to use WindowsMobileDownloader on PPC.