Pages

Wednesday, September 28, 2011

BIWUG on SharePoint Governance and the past, the present and the future

BIWUG is announcing another session about SharePoint on Thursday October 27th 2011 in the Microsoft Belgium offices.

Agenda

18:00-19:00 Welcome with snacks

19:00-19:15 Introduction

19:15-20:15 SharePoint Governance (Speaker Patrick Sledz): Stop thinking about features features features when talking about governance.

When designing governance for a SharePoint implementation, a lot (not to say all) energy and words go out to technical stuff, SLA's and not to the things that define the business value. And the business value is not only a perfect technically tuned and performant SharePoint farm (if that even exists).

20:15-20:30 Break

20:30-21:00 The past, present and the future of BIWUG

During a seemingly quiet period, a lot has been going on behind the scenes. The result of all this secrecy will be revealed in the second part of the evening.

21:00-21:30 SharePint!

Of course there is also an opportunity to network, socialize and discuss the matter explained the previous hours... therefore SharePint!

Location: Microsoft Belgium Corporate Village - Bayreuth Building, Leonardo Da Vincilaan 3, 1935 Zaventem

Registration is now opened on the BIWUG site www.biwug.be

Sunday, September 25, 2011

Text to speech in windows phone 7

How to use cloud-based Microsoft Translator Service in windows phone 7 to translate text to speech.

In this article I am going to explain how we can take the leverage of cloud to solve the problem for Text to Speech translation. It’s pretty simple to archive such kind of functionality in windows phone 7 using Bing API. Here I will show how we can retrieve a list of languages supported by Microsoft Translator for the Speech API and speak the user’s input text.

First of all we must obtain a valid Bing API AppID, lets follow the below steps.

Step -1 Open below mentioned url to register your application. And follow the instructions to obtain a valid Bing API AppID.

http://www.bing.com/developers/appids.aspx
1

Step-2 Enter required information and obtain a valid Bing API AppID.

2


Once you register your application now we will be moving ahead with the windows phone 7 application developments and invoke the cloud service.

Step-3 Create a windows phone 7 application project.

WP_001

Step-4 To add web reference of the Microsoft Translator Service, we need to add a service reference to Windows Phone project. Right - click the Windows Phone Project in solution explorer, and choose Add Service Reference. Please see below pictures for the same.

http://api.microsofttranslator.com/V2/Soap.svc


WP_002

WP_003

WP_004

Step-5 Now adds a panorama page to windows phone 7 project.

WP_005

Step-6 creates a UI as per application requirement see below xaml code snippet. Here I have added three panorama items.



<Grid x:Name="LayoutRoot">
<controls:Panorama Title="text to speech" Name="panoSpeech" Foreground="Blue" FontFamily="Comic Sans MS">
<!--Panorama item one-->
<controls:PanoramaItem Header="Language(s)" Foreground="Plum" FontFamily="DengXian" FontSize="72">
<StackPanel Orientation="Horizontal">
<StackPanel.Resources>
<DataTemplate x:Key="LanguageTemplate">
<TextBlock Foreground="White" Margin="0,0,0,0" Text="{Binding Name}" />
</DataTemplate>
</StackPanel.Resources>
<ListBox HorizontalAlignment="Left" ItemTemplate="{StaticResource LanguageTemplate}" Margin="20,10,0,20" Name="ListLanguages" Width="441">
</ListBox>
</StackPanel>
</controls:PanoramaItem>

<!--Panorama item two-->
<controls:PanoramaItem Header="Speech" Foreground="Yellow">
<StackPanel Orientation="Vertical" Margin="20,0,0,0">
<TextBox Name="TextToSpeachText" Text="This Pavan Pareta, Microsoft Most Value able proffesional. He has written an application for windows phone 7" TextWrapping="Wrap" Height="350" />
<Button Content="S p e a k" Height="90" Margin="0,30,0,0" Name="btnSpeak" Width="338" Click="btnSpeak_Click" />
</StackPanel>
</controls:PanoramaItem>

<!--Panorama item three-->
<controls:PanoramaItem Header="Speak" Foreground="Violet">
<StackPanel Orientation="Vertical">
<Image Height="auto" Name="image1" Stretch="None" Width="auto" Margin="50 60 80 0" Source="/speak.jpg" />
</StackPanel>
</controls:PanoramaItem>
</controls:Panorama>
</Grid>


Step-7 Fist Panorama item used to develop for retrieving supported speech languages. To retrieve the supported language we need to call web service method “GetLanguagesForSpeakAsync”. The GetLanguagesForSpeak method only returns the language codes, for example, en for English and fr for French etc. see blow UI and code snippet.


WP_006


GetLanguagesForSpeakAsync takes two methods like AppID and object.

void MainPage_Loaded(object sender, RoutedEventArgs e)
{
try
{
FrameworkDispatcher.Update();
var objTranslator = new ServiceReference1.LanguageServiceClient();
objTranslator.GetLanguagesForSpeakCompleted += new EventHandler<GetLanguagesForSpeakCompletedEventArgs>(translator_GetLanguagesForSpeakCompleted);
objTranslator.GetLanguagesForSpeakAsync(AppId, objTranslator);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}

void translator_GetLanguagesForSpeakCompleted(object sender, GetLanguagesForSpeakCompletedEventArgs e)
{
var objTranslator = e.UserState as ServiceReference1.LanguageServiceClient;
objTranslator.GetLanguageNamesCompleted += new EventHandler<GetLanguageNamesCompletedEventArgs>(translator_GetLanguageNamesCompleted);
objTranslator.GetLanguageNamesAsync(AppId, "en", e.Result, e.Result);
}

void translator_GetLanguageNamesCompleted(object sender, GetLanguageNamesCompletedEventArgs e)
{
var codes = e.UserState as ObservableCollection<string>;
var names = e.Result;
var languagesData = (from code in codes
let cindex = codes.IndexOf(code)
from name in names
let nindex = names.IndexOf(name)
where cindex == nindex
select new TranslatorLanguage()
{
Name = name,
Code = code
}).ToArray();
this.Dispatcher.BeginInvoke(() =>
{
this.ListLanguages.ItemsSource = languagesData;
});
}

Step-8 Second Panorama item used to develop for speak text using SpeakAsync method takes four string parameters like AppId, SpeechText, SpeechLanguage, format. See below UI and code snippet.


WP_007


private void btnSpeak_Click(object sender, RoutedEventArgs e)
{
var languageCode = "en";
var language = this.ListLanguages.SelectedItem as TranslatorLanguage;
if (language != null)
{
languageCode = language.Code;
}
var objTranslator = new ServiceReference1.LanguageServiceClient();
objTranslator.SpeakCompleted += translator_SpeakCompleted;
objTranslator.SpeakAsync(AppId, this.TextToSpeachText.Text, languageCode, "audio/wav");

panoSpeech.DefaultItem = panoSpeech.Items[(int)2];

}

void translator_SpeakCompleted(object sender, ServiceReference1.SpeakCompletedEventArgs e)
{
var client = new WebClient();
client.OpenReadCompleted += ((s, args) =>
{
SoundEffect se = SoundEffect.FromStream(args.Result);
se.Play();
});
client.OpenReadAsync(new Uri(e.Result));
}


Step-9 Now builds the application and executes it.

WP_008WP_009WP_010

Download source code here

Thank you for your time.

Sunday, September 11, 2011

Supporting links for SharePoint Foundation 2010 Development training Part 1

Module 3 – Object Model

Module 4 – Client Object Models

Module 5 – SharePoint Permissions

Module 6 – Authentication with Custom Claims

Module 7 – Features and Solutions

Friday, September 9, 2011

Attaching Virtual Hard Disks (VHD) in Windows 7 and Windows Server 2008 R2

Attaching VHDs in Windows 7 works quite easily – just go to Computer Management > Disk Management. Select the Attach VHD in the Actions menu.



Works like a charm.

Tags van Technorati: ,,

Thursday, September 8, 2011

BoxFiles for Dropbox v2 Beta

          Dear readers,
  We've just published the first beta of BoxFiles for Dropbox Mango edition :). The beta is available at: zune://navigate/?appid=8cfa8f66-3174-48e1-99b5-f2d0146113e8 and is limited to the first 100 users that will download the app (if we reach that limit and we still have requests we can publish another beta). We've rewritten most of the source code so it needs a good testing and some feedback. Send your problems/suggestions to: info@neologics.eu .
  The Dropbox library was rewritten from scratch taking out all the 3rd party components (JSON.Net and Hammock), but the featureI am most proud of is the integration with Skydrive. You can now upload your modified Office files back to your Dropbox account.
    We need your help to make our product better. If you can, please tweet the link.

NAMASTE!

Thursday, September 1, 2011

Mobile HTML5 Speed Reading Again

 Today I've upgrade my iPad 2 to iOS beta 7 and I was thinking that a more "realistic" comparison for the HTML5 Mobile Speed reading would with the new iPhone compared to a new Windows Phone Mango device (new year new hardware). On my Omnia 7 with 7712 build and video drivers not optimized for Mango I get around 30fps, the same that I was getting on my iPhone 4 with iOs5 beta. I remember that on a tweet I read that, on some devices, Windows Phone 7.5 Mango was doing 60 fps. On the other hand the new iPhone will probable have the A5 processor just like the iPad2 so I've run the same test on my device and the results are not bad at all. The iPad2 with iOs5 beta 7 is doing a stable 60fps. This is the frame rate we can expect from the new iPhone.So Apple and Microsoft are, for now, at the same level and let's hope that the OEM's will optimize their video drivers for Mango in order to get 60 fps, if not it could be a boomerang for Microsoft (the new iPhone, doing 60fps, would smash WP7 Mango that is doing 30-40fps). Hope it won't happen.

Here is the test on the iPad2

NAMASTE