Friday, February 2, 2018

Just quick issue I had with Flutter.


"You have not accepted the license agreements of the following SDK components: [Android SDK Build-Tools 26.0.2]."

I ran this command on my PowerShell - "flutter doctor --android-licenses" but it didn't work. I did this to fix it.

 I am on Windows so..

Run powershell with (Admin right) then type "android update sdk" into command line. then install the version you need to run, mind was 26.0.2. Select and install. Restart the powershell or your IDE.

That should do it.

Thursday, November 15, 2012

SignalR - Testing Microsoft.AspNet.SignalR –pre version


Getting SignalR 1.0 -pre release up and running.


I will share how to get a very very simple SignalRapp up and running.  plus the code to download.

*This app doesn't do much but just so that you can see how it works.  But it took me many hours since there are several versions out there and API changes so much so that none of the apps will work with different version of the SignalR.

Prepare

I've been trying to learn about SignalRand today was it.  I did a nuget inside of visual studio and used the Install-Package SignalR command and that got me SignalR .5.3.  But it's not what I saw at the MS Build conference.  After some research I found a link to download a pre-release version of SignalR1.0.

This is what you want to do.

  1. download Microsoft ASP.NET Fall 2012 Update BUILD Prerelease from here -http://www.microsoft.com/en-us/download/details.aspx?id=35493
  2. Nuget comand is Install-Package Microsoft.AspNet.SignalR –pre 
#1 will get you latest stuff for asp.net mvc stuff including class templates for SignalR.
#2 will install latest SignalR files including SignalRpre release version 1.0


Code

I will share how to get a very very simple .net C# code.  I am using vs 2012.  project is called signalR1pre.zip
what you will find on that project.

  1. installed packages so you don't have to
  2. look at home.html on the root which should work
  3. same code in home/index.cshtml.  (I had to wrap it inside of @section Scripts so that I won't get this error message: TypeError: $.connection is undefined)

#3 can happen if you referenced jQuery twice.

Download link
SignalR code


for reference:
http://weblogs.asp.net/davidfowler/archive/2012/11/11/microsoft-asp-net-signalr.aspx

Sunday, July 15, 2012

Microsoft, why you no like developers developers developers???



I am a .net developer.  I also develop in IOS and Android.  I wanted to look into Metro with winRT so I bought a new laptop with 14 gb memory and installed the windows 8 consumer preview release.   It's little buggy and has serious windows update issue.  Check out my previous blog.  Metro screen to desktop is not so smooth and that damn charm bar is so hard to get to.  How the hell do you kill running apps in Metro screen.  I hope Microsoft fixed all these in finally release or else there is not point developing anything in Metro.  But anyway I want to talk about developing (complains) in Metro today.

I already have projects that I developed which took many many months or my life so I wanted to use existing .net dlls.  But I CAN NOT reference it in Metro app.  It will not let you.  So I decided to port it over to Metro library project but Metro library project will not reference the 3rd party dlls either, WTF.  This is a serious issue for me.  I do not want to rewrite the same code over again.  The fact that they wont' let you use existing code is terrible.  Why couldn't they throw in another layer of abstraction like bridge layer or something.  I was thinking about developing my app in Metro but I am now thinking why not use IOS iPad at this point if I have to start it all over again.

My solution?  well...  I am thinking about using web api in MVC.  I can run it locally as a windows service or  web service and call json object and use it in Metro app.  That should work but it's not the best idea either.  I am going to try this and report back.

Microsoft, why you no like developers.....

boy,  that feels little better.


Update: I found this link http://blogs.msdn.com/b/piyushjo/archive/2011/10/10/calling-a-wcf-service-from-a-metro-application.aspx

I am going to try this.

windows 8 consumer preview crashes after recent windows update

I have an Asus laptop and running windows 8 consumer preview release.  I know running preview is not a good idea but I am a developer and needed to test Metro apps.

I just updated [7/15/2012] new windows update and it crashed my laptop.  I think it was video driver issue. It flickered with blue screen and repated this over and over.

To fix this issue press shift + F8, which will take you too safe mode and roll back the previous by doing system restore.  That's the only way I know how since everything else failed to do so but that should work.

Good luck.  Thanks MS.

Thursday, August 18, 2011

creating custom short cut snippet in visual studio for MVC

Someone you may know about short cuts in visual studio but do you know how to create your own?

you can use "ctor" and tab tab to get this
public HomeController()
{
}

"prop" and tab tab for
public int MyProperty { get; set; }

but you can create one like "view" to create this
public ActionResult foobar()
{
return View();
}


This is how
1. go here C:\Program Files\Microsoft Visual Studio 9.0\VC#\Snippets\1033\Visual C# (for visual studio 9)
2. copy of those file and change the name to like "view.snippet" and update the xml file.


<?xml version="1.0" encoding="utf-8" ?>

<CodeSnippets  xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">

<CodeSnippet Format="1.0.0">

<Header>

<Title>view</Title>

<Shortcut>view</Shortcut>

<Description>Code snippet for an automatically implemented property</Description>

<Author>Wil</Author>

<SnippetTypes>

<SnippetType>Expansion</SnippetType>

</SnippetTypes>

</Header>

<Snippet>

<Declarations>

<Literal>

<ID>name</ID>

<ToolTip>View Name</ToolTip>

<Default>foobar</Default>

</Literal>

</Declarations>

<Code Language="csharp"><![CDATA[public ViewResult $name$()

{

return View();

}]]>

</Code>

</Snippet>

</CodeSnippet>

</CodeSnippets>


Now you type in "view" and tab tab in the HomeController or whatever else and you shoudl get this
public ActionResult foobar()
{
return View();
}


that's all.

more info here http://msdn.microsoft.com/en-us/library/ms165394.aspx

and I used http://www.simplebits.com/cgi-bin/simplecode.pl to convert xml code so that that blogger will allow me to enter the xml code.

Saturday, August 13, 2011

Google Plus Game Development

I am thinking about create a Google+ game using html5 with jQuery.  I just got a game tab from on my Google+ account.  Here is a link to Google+ team about it.  http://googleblog.blogspot.com/2011/08/games-in-google-fun-that-fits-your.html  and google dev team blog here http://googleplusplatform.blogspot.com/2011/08/stepping-onto-google-platform.html.


I just signed up for Google+ developer.  waiting for the email now.


Sunday, April 17, 2011

mvcscaffolding

This is for anyone interested in doing scaffolding in asp.net mvc.

http://blog.stevensanderson.com/2011/01/13/scaffold-your-aspnet-mvc-3-project-with-the-mvcscaffolding-package/

http://channel9.msdn.com/events/MIX/MIX11/FRM13

//get-scaffolder : see what functions are available

Install-Package MvcScaffolding
Update-Package MvcScaffolding
Uninstall-Package MvcScaffolding -RemoveDependencies

Scaffold Controller Team -Force
Scaffold Controller Team –Repository -Force
Scaffold Action Team About -CreateView Model -Force
Scaffold Action Team About -CreateViewModel -Force
Scaffold Action Team About -CreateViewModel -Force -Post

Scaffold UnitTest Team Registration -VewModel AboutViewModel

Scaffold customTemplate UnitTest TestClass
Scaffold customTemplate UnitTest TestMethod