DCSIMG
or ben shmueli

or ben shmueli

Press any key to continue, where's the any key? - Homer.S

Get Tfs Items to Windows Phone using WCF

Hello everyone

Today I will show you how you can keep track of bugs in TFS through the windows phone

True at the beginning it sounds like those who really need it ... But everyone who works from home, without connecting to the office need it! or just some one that want to know what remains to do

Of course the guide is basic, and it demonstrates just how to get the data from TFS SERVER but of course you can also update the server data (next post), and possible also to obtain data on all employees ... In short the sky is the limit

Step 1

Of course we open windows phone application

1

Because of windows phone connect to TFS directly we will perform it with WCF

And add a new project of WCF

2

Add to the service of TFS DLL

3

step 2

We will change the interface and add our functions

4

In the Function, we put the following code:

5

The code actually going to TFS and takes away from the data of course just the code returns all the rows listed in TFS but can take a per-user, type, status, etc.

At the code registered How can you reduce some of the data how can access them.

we finished with the WCF of course you also can be used for more applications other than windows phone.

Now we switch to windows phone application

step 3

Add to the application a listbox (it will be with all the bugs/tasks)

6

And the following code:

7

Just beauty and able to show more can be done I added alert while clicking on the listbox to show the entire text of the task which is a record in TFS

8

And so it seems to be activated

9

And so when you click on one of Bug

10

Windows Phone GIS using Bing-Maps part 2

i changed a little bit the Gui from the old post, i add Textbox and a button and now it look like this:

a1

 

i add this 2 functions:

private void GoBtn_Click(object sender, RoutedEventArgs e)
     {
         ServiceReference1.SearchServiceClient _client = new SearchServiceClient();
      
         ServiceReference1.SearchRequest sr = new SearchRequest();
         sr.Credentials = new Credentials(){ApplicationId=_key};
         sr.Query = Searchtext.Text;
         _client.SearchAsync(sr);
         _client.SearchCompleted += new EventHandler<SearchCompletedEventArgs>(_client_SearchCompleted);
     }

     void _client_SearchCompleted(object sender, SearchCompletedEventArgs e)
     {

         // it returns a list of locations i just take the first one
         if(e.Result.ResultSets.ElementAt(0).Results.Count > 0)
         {

             GeoCoordinate gl = new GeoCoordinate();
             gl.Altitude = e.Result.ResultSets.ElementAt(0).Results[0].LocationData.Locations[0].Altitude;
             gl.Latitude = e.Result.ResultSets.ElementAt(0).Results[0].LocationData.Locations[0].Latitude;
             gl.Longitude = e.Result.ResultSets.ElementAt(0).Results[0].LocationData.Locations[0].Longitude;
           
             map1.SetView(gl,17);
          }
          }

 

and that`s it!

when you push seaview seattle it look like

a3

Windows Phone GIS using Bing-Maps

Hello everyone
Today the blog will discuss how to create GIS windows Phone application using Bing Maps,
First you must register at Bing developer site for downloading the water mark of the Bing link:
http://www.bing.com/developers/appids.aspx
after you registered opened VS 2010 and select windows Phone application:

We add the component side bing map


we add listbox of cities for now (next post we'll see how we do it with just the address with only a textbox!!)
Add to listbox four cities (you can add class of the city that will include the long and lat with the name... that will be in the next post :))

the Selection will make map go to the city
Important to know:
1) have the coordinates (latitude, longtitue)
2) The zoom is how far we see the map bigger it got closer to earth zoom
To the presentation i used at 10

3) the cord`s you can find in wiki - just search it...


this is how it look on load (see all the world)

So after clicking on the London

Enjoy, and continue to follow the blog

 

Posted: Mar 28 2012, 10:17 PM by orbens | with no comments
תגים:, , , ,

Make our own Asp.net Moblie Web Site

Hi ,
At times like ours that every day a new mobile device release and a variety of resolution is growing every day and (around 7),
also we want to build one site that you could see him same for all these sizes.
And if I come and tell you that there is a solution, even very easy to do, not only solve the problem with the seven resolutions,
also a solution that you can see on your home computer and Tablets very well (not perfect but still worth ...)
furthermore, the site can be done in asp.net and all devices/OS will support it.
This solution is called jQuery Mobile
in This blog I'll show you how you can build a website to Moblie, suit all resolutions as well as your home course using C # and jQuery Mobile.
All the capabilities of C # do not disappear, and the site functions like a standard asp.net website (for home users) and only in Mobile is displayed like an application.

this blog is not talking about the Tablets but it is also the exactly as on the Mobile.

First we open a new webappliction using the VS.

after we opened go to this link and download the Jquary Mobile add this 4 links to the Header of the html

step1

<meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.css" />
  <script type="text/javascript" src="http://code.jquery.com/jquery-1.6.3.min.js"></script>
  <script type="text/javascript" src="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.js"></script>

Mobile page structure

The jQuery Mobile have to start with <DOCTYPE> tag just like the HTML 5 and has a fully support at the HTML 5 features.

the head section need to be like that :


<!DOCTYPE html> 
<html> 
	<head> 
	<title>Page Title</title> 
	
	<meta name="viewport" content="width=device-width, initial-scale=1"> 

	<link rel="stylesheet" href="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.css" />
	<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.3.min.js"></script>
	<script type="text/javascript" src="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.js"></script>
</head> 

<body> 
...content goes here...
</body>
</html>
step2

Inside the body: Pages

in the <body> tag foreach page the the mobile you need to have a (usally a div ) with an attribute that call – data-role = "page" you have also a "popup" and many more.

you can have more then one page at the ASPX page it called Multi-page .

the "page" can be placed only Over the "header" , "content" and "footer" only.

but you not have to write the header content and footer , for the jQuery you need to write "data-role=page" and it will be for Mobile.

there is an example for the Page div:.

<div data-role="page">
<div data-role="header">...</div>
<div data-role="content">...</div>
<div data-role="footer">...</div>
</div>

 this is the HTML after we combind all together :

<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>

<meta name="viewport" content="width=device-width, initial-scale=1">

<link rel="stylesheet" href="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.css" />
<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.3.min.js"></script>
<script type="text/javascript" src="http://code.jquery.com/mobile/1.0b3/jquery.mobile-1.0b3.min.js"></script>
</head>
<body>

<div data-role="page">

<div data-role="header">
<h1>Page Title</h1>
</div><!-- /header -->

<div data-role="content">
            <asp:Label runat="server" ID="testpnl"></asp:Label>
</div><!-- /content -->

<div data-role="footer">
<h4>Page Footer</h4>
</div><!-- /footer -->
</div><!-- /page -->

</body>
</html>

step3
C# code:

protected void Page_Load(object sender, EventArgs e)
{
     WriteTojQuary();
}

private void WriteTojQuary()
{
     testpnl.Text = "some text...";
}

we test on the PC
step4
we test it on the Mobile and this is the resualt
shot_000004
look the same סמיילי