Showing posts with label Microsoft. Show all posts
Showing posts with label Microsoft. Show all posts

Monday, September 16, 2013

Odyssey of Installing Windows Phone SDK 7.1 in Windows XP

You decided to develop a Windows Phone Application, you thought that Windows Phone 8 SDK is a good opportunity to start with as Microsoft represents it as something awesome and you think that Microsoft should have covered the gap between Windows Phone 7 and Android or iOS.

You visit http://download.microsoft.com/ but Windows Phone 8 SDK is not there, but you are a newbie in Windows Phone development so you download Windows Phone 7.1 SDK in order to start....your enthusiasm does not let you to read the requirements and you have Windows Phone 7.1 SDK and a laptop with Windows XP SP3 and Visual Studio 2010...damn you should have read the Release Notes. Windows XP is not compatible with Windows Phone 7.1 SDK.

"Windows 7 or Windows Vista is required" but if you want to be nerd this cannot stop you.
You start searching and some workarounds will appear.  You can follow the steps below:

  1. Download the Windows Phone Developer Tools CTP Refresh
  2. Extract the contents of the setup package by running vm_web.exe /x and choosing a path to extract to
  3. Go to the folder you extracted to in step 2 and open the file baseline.dat in notepad
  4. Look for the section named [gencomp7788]
  5. Change the value InstallOnLHS from 1 to 0
  6. Change the value InstallOnWinXP from 1 to 0
  7. Save and close baseline.dat
  8. Run setup.exe /web from the folder you extracted to in step 2
You follow the wizard and you have the SDK installed on your Windows XP computer.
After the installation you need to update to 7.1.1 (http://www.microsoft.com/en-us/download/details.aspx?id=29233).

The Windows Phone Developer Tools includes the following
  • Visual Studio 2010 Express for Windows Phone
  • Windows Phone Emulator Resources
  • Silverlight 4 Tools For Visual Studio
  • XNA Game Studio 4.0
  • Microsoft Expression Blend for Windows Phone 
Full of joy and pride that you achieved to install it you open Visual Studio, you create a blank Silverlight application and you press F5...in order to see the emulator...You cannot connect to the emulator...The following error occurs:

"The delay loading of ... or this DLL was missing an ordinal. Execution cannot continue."
This issue is due to a missing DLL called bcrypt.dll. This DLL is only included in Windows since Windows Vista. You can't copy it to your Windows XP from a Windows Vista installation, the DLL depends on new functionalities provided by ksecdd.sys. The hack consists of emulating the bcrypt functions needed by xde.exe.

Fortunately, XDA Developers Forum has the solution as you can see below:

http://forum.xda-developers.com/wiki/Windows_Phone_7_Emulator

This was the last step of the installation, restart your PC and you are ready, Happy Coding.

Sunday, October 2, 2011

How to make LINQ query to Sharepoint 2010 across Site Collections

 I'm currently member in a development team, working on a project on Sharepoint 2010, and one of the tasks is to execute LINQ query on Sharepoint objects, that's ok, seems quite simple as we have experience on LINQ.

But when we tried to apply the same query across site collections we realised that despite the fact that the correct site collection is opened, we couldn't read the objects.

During searching on the internet we found a workarround by changing the SPContext before executing the LINQ query.

In the webpart itself the HttpContext is stored in a variable before executing our search method.


We have found the cause of this problem. When an SPContext is available (like in the webpart), the constructor of SPServerDataConnection tries the open the url in the SPSite of the context.

So querying a linq datasource in a different site collection doesn't work whenever an SPContext object is available.

We managed to reproduce this problem in our console application by createing a fake SPContext object which causes the same error.

Microsoft.Sharepoint.Linq.Provider - SPServerDataConnection:

public SPServerDataConnection(string url)
{
    if (SPContext.Current != null)
    {
        this.defaultSite = SPContext.Current.Site;
        this.defaultWeb = (SPContext.Current.Web.Url == url) ? SPContext.Current.Web : this.defaultSite.OpenWeb(new Uri(url).PathAndQuery);
    }
    else
    {
        this.defaultSite = new SPSite(url);
        this.defaultWeb = this.defaultSite.OpenWeb(new Uri(url).PathAndQuery);
    }
    if (!this.defaultWeb.Exists)
    {
        throw new ArgumentException(Resources.GetString("CannotFindWeb", new object[] { url }));
    }
    this.defaultWebUrl = this.defaultWeb.ServerRelativeUrl;
    this.openedWebs = new Dictionary();
    this.openedWebs.Add(this.defaultWebUrl, this.defaultWeb);
}

So, we tried to cheat on the application, below you can see the solution:

In the webpart itself the HttpContext is stored in a variable before executing our method.

SPSecurity.RunWithElevatedPrivileges(delegate()
{
     using (SPSite contextSite = new SPSite("http://"))
     {
          using (SPWeb contextWeb = contextSite.OpenWeb())
          {
               HttpRequest httpRequest = new HttpRequest("", contextWeb.Url, "");
               HttpContext.Current = new HttpContext(httpRequest, new HttpResponse(new StringWriter()));
               SPControl.SetContextWeb(HttpContext.Current, contextWeb);               
               using (MyLinqDataContext dc = new MyLinqDataContext("http://"))
               {
                    EntityList entities = dc.GetList("");
                    {
                    }
               }
           }
     }
}


After performing the query we set the HttpContext back to the original HttpContext. 


tempContext = HttpContext.Current;
this.Search();
HttpContext.Current = tempContext;


I'm not sure if this workaround is appropriate, but at least we can now perform our cross site collection LINQ query in our webpart.

Wednesday, June 22, 2011

Some ways to use Sharepoint

I’ve found that people have a general idea of what SharePoint is, but many have no idea how to apply it to their own business and as a result they spend a lot of valuable time to analyse, design and develop applications for their needs. So, I’d like to share some ways that SharePoint can solve your common business needs.

I want to emphasize that listed ways are only a few of the many ways to utilize the SharePoint Services. Once you start using it, you will begin to realize the many other valuable benefits that can easily be accomplished by the everyday user. Let’s see if you can find a few productivity solutions here that you've been trying to find for your own business, organization or daily routine.


With SharePoint you can:
  • SharePoint helps you build powerful business solutions using new features such as Language Integrated Query (LINQ) to SharePoint, OData Services, and the Client Object Model. You also can use Business Connectivity Services to pull external data, complete with read/write capability.
  • Collaborate with team members on all documents and stay on top of who did what. Earlier versions can easily be restored in case someone has made too many mistakes. Projects can also be linked to related documents.
  • Keep a central task location for assigning tasks to team members. These tasks will automatically show up in your team's Outlook 2007 To-Do List. Those tasks will also link to your projects so you can easily find out what tasks are still open for each project.
  • Store all your emails on a secure and centralized Website for easy archive.
  • Helps in project management by assigning tasks to your team members, and automatically notify them that they have a new task. Alerts are sent when there have been updates to the tasks.
  • Organize large events and store the related documents, assigned tasks, and generally post anything and everything related to the events. It will also integrate with Outlook for added efficiency.
  • Manage all projects for your team or organization so there's no need to explore buying an expensive project management solution.
  • Implement a help ticket resolution for your organization or  team without breaking the bank.
  • Use the efficient check-in / check-out management feature to sort your documents.
  • Start a private company blog to communicate and share ideas with your team that's viewable only by those you give access to.
  • Gain more control over your company's documents with the content approval function.
  • Offer training materials to your teams, clients, and/or partners in a password-protected Website that can be accessed anywhere in the world.
  • Offer a secure and private place to share documents and other information with clients and/or partners.
  •  Create better team communication and brainstorming sessions where everyone can participate when their schedules permit.
  • Centralize where company and team project announcements are posted. Everyone will receive a notification via email or mobile phone automatically, anywhere in the world.
  •  Access and work with your data using your Internet-enabled mobile phone for added convenience while traveling or out of the office at client meetings.
  •  Create "central" documents (and syncronize), so all team members, clients, and/or partners are able to work on the same document and make changes. Updates are accessible with a click of a button. Everyone can then sync back to the "central" document and have all edits merged into that single document.
  • Create a project dashboard where on one page you can view and filter on common project elements, such as: project details, project documents, project tasks, project issues, project calendar, project milestones, project lessons learned, project risks, project change orders, and more.
  • Pull up and update Microsoft Access 2007 database from a local desktop and sync information to a central location that can be accessed from any where at any time.
  •  Easily add custom fields to any area and capture the information that's most important to your company, all without the help of a web designer or IT person.
  •  Work offline on the files, project tasks, tasks, discussions, contacts, calendars, blogs, etc. and then sync the updated information later on.
  • Create "central" documents (and syncronize), so all team members, clients, and/or partners are able to work on the same document and make changes. Updates are accessible with a click of a button. Everyone can then sync back to the "central" document and have all edits merged into that single document

And last but not least, saves you from spending a fortune to meet these communication, collaboration, and organizational needs.

Sunday, February 20, 2011

Nokia baits developers with free Windows Phones


Microsoft and Nokia may have spent much of Mobile World Congress trying to convince attendees of the merits of their fresh, new partnership, but the harder step will perhaps be urging Nokia's loyal Symbian developers to shift alliances.


There's nothing like free stuff to help change one's mind. To that end, Nokia will be giving away one E7 smartphone and one Nokia-made Windows Phone to each developer in Launchpad, it's program for mobile app developers, according to information procured by SlashGear.


In addition, Nokia will waive its tech support charges for developers for the next three months. 
Developer support is one key to make Nokia's Microsoft pairing successful, especially as the two companies are poised to battle Canada's Blackberry maker RIM for market relevance behind Apple's iOS and Google's Android platforms.


On the handset front, Nokia will also feel pressure from Sony Ericsson, as both brands will keep a hungry eye trained on the US smartphone market.




Source: http://www.cnet.com/

Friday, February 11, 2011

Nokia, Microsoft becoming Windows Phone bedfellows

Microsoft and Nokia announced a broad mobile phone partnership today that joins two powerful but lagging companies into mutually reliant allies in the mobile phone market.
As expected, Nokia plans to use Microsoft's Windows Phone 7 operating system as part of a plan to recover from competitive failings detailed in Nokia Chief Executive Stephen Elop's "burning platform" memo.

But it's deeper than just an agreement to install the OS on Nokia's phones. Instead, the companies call it an attempt to build a "third ecosystem," acknowledging that competing with Apple's iOS and Google's Android involves a partnership that must encompass phones, developers, mobile services, partnerships with carriers, and app stores to distribute software.

Nokia CEO Stephen Elop, let, and Microsoft CEO Steve Ballmer explained their company's new tight alliance for mobile phones at an analyst and strategy meeting in London.

"There are other mobile ecosystems. We will disrupt them. There will be challenges. We will overcome them. Success requires speed. We will be swift," Elop and Microsoft CEO Steve Ballmer said in a boldly worded open letter. "Together, we see the opportunity, and we have the will, the resources and the drive to succeed."

The companies will cooperate tightly under an agreement the companies just describe so far as proposed, not final. Under the deal, Windows Phone 7 would become Nokia's "principal" operating system, and Nokia would help Microsoft develop it and ensure a broad range of phones using it are available globally.

Nokia will use many Microsoft online services, many of which trail Google rivals, such as Bing for search and maps and AdCenter for advertisements.

When it comes to the sales part of the ecosystem, each company brings something to the deal. Microsoft phones will be able to link up with Nokia's agreements for carrier billing--a popular option in parts of the world where credit cards are less common. And Nokia will fold its own app store into the Microsoft Marketplace.


Elop the optimist


In a press conference today, Elop and Ballmer touted the alliance as good for both companies' aspirations.

"A pessimist sees the difficulty in every opportunity, but an optimist sees the opportunity in every difficulty," Elop said, quoting England's historic prime minister Winston Churchill as he spoke in London. "I am an optimist."

It's not immediately clear what needs to be done to make the deal final; details "specific details of the deal are being worked out," the companies said.

Nokia, once the dominant power of the mobile phone industry, has ceded the smartphone initiative to Apple's iPhone and Google's Android, and Elop believes Nokia's own Symbian and MeeGo operating systems aren't competitive. Microsoft has tried for years to penetrate the mobile phone market, and although it now has a credible option with Windows Phone 7, it trails Android when it comes to developer interest and the breadth of phones available.

The two companies can expect their combined might will be more convincing for software authors debating whether they need to bring their apps to yet another ecosystem. But it's not yet clear how the alliance will extend to another hot new market, tablets, where Microsoft prefers Windows instead of the Windows Phone operating system. In contrast, iOS and Android developers enjoy the same mobile operating system on phones and tablets.

An end for Symbian, MeeGo


The partnership means a gradual end for both Symbian and MeeGo, Nokia's mainstream and next-generation smartphone operating systems, respectively. Symbian will be gradually phased out in favor of Windows Phone, though Nokia expects to ship 150 million more Symbian phones in the meantime.

And although Nokia will ship a single MeeGo-based smartphone later this year, Elop consigned it to near-oblivion by calling it merely "an opportunity to learn." MeeGo engineers will "change focus into exploration" of future devices and user services.

Nokia seriously considered using Google's Android operating system, but feared it would ultimately be a boon for Google and a bane for Nokia, Elop said.

"We would have difficulties differentiating within that ecosystem," Elop said. Joining the Android world would make it even bigger, "with prices, profits, and everything being pushed down, and value moving to Google."


Nokia cost-cutting


Along with Nokia's new operating system strategy come major internal changes. Leadership in the United States, a large market now awakened to smartphones but where Nokia trails particularly badly, is being replaced. Bureaucracy will be cut. Research and development costs will be cut but R&D will become more productive. And there will be substantial layoffs, in Finland and elsewhere, Elop said, though the company will not move headquarters anywhere else.

"Already evolving rapidly at Nokia is a change in attitude and behavior" that shows "the fighting spirit of Nokia worldwide and the fighting spirit of the Finnish people," Elop said. In communicating with employees about the change, including an company-wide message earlier this morning, he added, "We've been vocal and transparent about the challenge. I think it's having a positive effect."

Nokia will pay Microsoft royalties for use of its operating system, but apparently money will likely flow the other way, too, Ballmer and Elop said.

"We have different forms of value transfer in different directions," Elop said. "We have new opportunities that come from advertising and new forms of monetization."

"We the ability to activate users and put them in a position to be more effective in what we call local commerce," added Ballmer. "Nokia has not just got mapping but other assets that we will import, if you will. There are a set of financial considerations for that as well."

Elop and Ballmer detailed their proposal immediately before the vast Mobile World Congress trade show in Barcelona, Spain, where a large number of new Android phones and tablets can be expected.

It's uncertain what effect the alliance will have. Microsoft has had strong operating system partnerships with multiple competing PC makers, but the Nokia alliance, with mutually developed products and shared road maps, appears much deeper than the average relationship Microsoft has with hardware makers. That could encourage those who've made strong Android commitments--HTC, Motorola, Sony Ericsson, LG Electronics, Samsung, and more--to double down. After all, they're all enjoying a period of relative freedom with Nokia in its present relatively uncompetitive state, and strongly pushing Windows Phone products arguably would be abetting the enemy.

Although the alliance is nonexclusive, Nokia clearly is becoming the premier Windows Phone partner. "There are things we are planning to do with Nokia that are unique," Ballmer said.

The announcement was accompanied by a YouTube video featuring Microsoft and Nokia's chief executives praising the deal.

"Today, Nokia and Microsoft intend to enter into a strategic alliance," Elop said in the video, a precursor of a turnaround plan he's set to detail later today at an analyst conference in London. "Together, we will bring consumers a new mobile experience, with stellar hardware, innovative software, and great services. We will create opportunities beyond anything that currently exists."

Ballmer said the partnership "brings the brands mobile consumers want, like Bing, Office, and of course Xbox Live."


Source: http://news.cnet.com/

Tuesday, January 25, 2011

Microsoft goes on the iPad offensive


Microsoft may have laid out its plans to have Windows running on any device while unveiling the next version of Windows at CES earlier this month, but it's not there yet. In the meantime, we're still stuck with the current version of Windows, which, for better or for worse, cannot fit into the types of devices its successor promises to fit.


That very situation--along with a lack of product from Microsoft's hardware partners, has led to a relative dearth of Windows 7 in tablet PCs. It can also be argued that it's responsible, in part, for what has turned out to be much stronger than expected sales for the iPad, of which Apple sold 7.33 million units during the last three months of 2010, nabbing the "best-selling tech gadget in history" title following its introduction.


   One of the slides detailing how Microsoft stacks up Windows 7 devices with Apple's iOS on the iPad.


But Microsoft's got a plan to position Windows 7 as the better of the two computing platforms. In a set of slides sent out to its reseller partners, and acquired by CNET sister site ZDNet, Microsoft has outlined the various ways in which Windows offers more security and breakout features, while also being more of a chameleon--working its way into more than just one hardware form factor.
The 10 slides, which you can view on ZDNet, focus mainly on the enterprise, highlighting key differences where Windows checks all the boxes for things like getting work done offline, supporting Microsoft Office and its data synchronization tools, and working with existing lines of business applications. But Microsoft also takes the iPad to task on compatibility with things such as support for peripherals, security protocols, Adobe's Flash and Microsoft's own Silverlight.
At the heart of Microsoft's argument, though, the company paints the iPad as a consumption device that doesn't play nice with existing enterprise security or application standards. To back that up, the company breaks down the ways in which Windows 7 slate form factor PCs have three distinct advantages over the iPad: optimization for online and offline data use, a design for both consuming and creating content, and support for peripherals. Microsoft also highlights Windows' pen and writing technology, speech recognition, and touch support, alongside its natural user interface and video technologies, all of which it deems to be "rapidly changing."
For companies on the fence about bringing the iPad into their business, Microsoft is going with a "one size does not fit all" approach, noting that some companies may need devices that work better with their security and compliance needs. The more telling look, though, is what Microsoft is trying to pitch to companies already using, or plan to use, Apple's iPad. Microsoft is telling those partners to "implement a Virtual Desktop Infrastructure (VDI) to reduce risk in your enterprise," meaning that they'd be making use of tools like Microsoft's Hyper-V Server, and App-V.
During last year's CES keynote, Microsoft's CEO Steve Ballmer paid special attention to a group of Windows 7 slate concepts, though the only one of the bunch that made it to consumers' hands during 2010 was HP's Slate 500 device. At this year's show, slates were all but missing from the company's keynote, instead being replaced by myriad devices designed to show off Windows' next ARM capabilities. What's still unclear is whether Microsoft's more nascent, though already ARM-friendly, Windows Phone OS will make its way into a tablet form factor, something speculated about since the platform's introduction at last year's Mobile World Congress.




Source: http://news.cnet.com/

Monday, January 17, 2011

Microsoft Gives Semi-Pros a Free Web Dev Toolbox

Micrsoft's WebMatrix is designed to let website developers with even low skill levels easily create and publish Websites. "It's a programming environment, and it's quite complicated," Web devAaron Hee-Stacpoole said. "I'd say that stating beginners can use it is not quite accurate. You can't have something that's really powerful and also easy to use -- it's somewhat of a paradox. I think semi-pros will use it."


Microsoft on Thursday released WebMatrix, a free Web development tool that it claims lets website developers of all skill levels create, customize and publish websites to the Internet easily.


It also announced an ecosystem of 40 open source application partners around WebMatrix.


This is a revival of a previous project, also called "WebMatrix," that offered a free tool in 2002 to help Web developers get started with ASP.Net, Microsoft representative Jackie Lawrence told TechNewsWorld.


Microsoft has long been at war with the open source movement -- could this be an attempt to re-establish its credibility with OSS adherents?


The Threads Making Up WebMatrix


WebMatrix includes IIS Express, a development Web server; ASP.net, which is a Web framework; and SQL Server Compact, an embedded database, Microsoft representative Lawrence said.


It also includes Razor, a new inline syntax for coding pages that adds dynamic functionality to HTML. This syntax minimizes the number of keystrokes required, Lawrence said. It doesn't require users to learn a new language.


Microsoft plans to use Razor with standard inline pages as well as with future ASP.Net MVC releases as an optional view engine, Lawrence stated. MVC stands for Model View Controller.


Microsoft's shipping a beta release of ASP.Net MVC 3 with WebMatrix and NuPack. ASP.Net MVC 3 enables clean separation between models and views, reducing complexity in architectural design and increasing the flexibility and manageability of the code, Lawrence remarked.


WebMatrix lets developers write code in HTML, CSS (Cascading Style Sheets) or JavaScript. Developers can use it to write HTML5 code, Lawrence said.


WebMatrix is integrated with the NuGet open source package management system. Formerly called "NuPack," NuGet lets developers who maintain open source projects package up their libraries and register them with an online gallery or catalog that's searchable. Client-side NuGet tools include full Microsoft Visual Studio integration.


WebMatrix supports multiple programming syntaxes, including ASP.Net, Razor and PHP, as well as Web helpers. Web helpers give a single line-of-code solution for complex coding tasks such as inserting Twitter feeds of video, Lawrence said.


Further, WebMatrix includes a search engine optimization reporting tool so users can build search-friendly websites.


Comments on WebMatrix


"This looks like a pretty strong offering from Microsoft," Web developer  Aaron Hee-Stacpoole told TechNewsWorld. "It looks like they've positioned themselves pretty well with content management services like Drupal. I don't think it'll dominate the industry but people will definitely use it."


However, newbies may not find WebMatrix quite so easy to use as Microsoft contends.


"It's a programming environment, and it's quite complicated," Hee-Stacpoole commented. "I'd say that stating beginners can use it is not quite accurate. You can't have something that's really powerful and also easy to use -- it's somewhat of a paradox. I think semi-pros will use it."


Thursday's release follows three betas of WebMatrix, first in July 2010 and then in October and subsequently November.


Open Is as Open Does


In addition to using the open source NuGet, Microsoft has rounded up 40 open source application providers in its WebMatrix system. They include Joomla and Umbraco, both open source content management systems.


These tie-ins could give rise to speculation that Microsoft's trying to mend its rocky relationship with the open source movement.


"Microsoft's a founding sponsor of the OuterCurve Foundation, and we have a collection of projects under the ASP.Net open source gallery," Paula Hunter, executive director of the OuterCurve Foundation, told TechNewsWorld. "All those projects either came to us from Microsoft or from people that are deploying .Net and who feel those projects are useful to the community."


OuterCurve was set up by Microsoft in September of 2009 as the CodePlex Foundation. It was renamed in September "because there was a lot of confusion between the Foundation and CodePlex.com forge, which is a Microsoft property and has no relationship with us," OuterCurve's Hunter stated.


The establishment of the CodePlex Foundation immediately drew fire from the Open Invention Network, an intellectual property company promoting Linux and open source. The Network had purchased 22 Linux-related patents Microsoft had previously sold to the Allied Security Trust. It accused Microsoft of engaging in a covert war against Linux.


Skepticism about Microsoft's intentions toward open source runs deep in the community.


However, this fact doesn't preclude peaceful coexistence between open source and Microsoft.


"I don't think WebMatrix will supplant any of the open source technologies," Hee-Stacpoole opined. "It will probably coexist with them as Microsoft as done in the past."