Using TFS with Eclipse

This article is from the experience I gain while setting out to complete my capstone and a point in time where I was exploring that ways to manage a team. I also wanted to help move things forward with the process for the team to code rather than spending more time on design. My capstone was along the side with three other colleagues and we did not all have the same idea with what systems or tools should be in place to help us achieve our tasks. Still after the fourth change of repository system in my team, I figured it was time that I took charge and started making changes for the better with my suggestion to use TFS.

Plugin: TFS Plug-in for Eclipse | Eclipse Plugins, Bundles and Products - Eclipse Marketplace

The following plugin behaves much like the native built-in tool for visual studio but with a slight twist for the  tab locations because of how eclipse is setup. At first when I started researching this plugin and testing it for for our android project I had worries of whether …

Visual Studio "Access Denied" When Checking in with TFS

The problem was that when I went to check in changes with Visual Studio, it would report back saying I did not have permission. I knew it couldn't have been the TFS setup because I had everything configured straight forward for a single user which was just me and I know it was fine since it was working a few days ago. The only thing that changed on my machine was the that I lost access to my domain account that I was working with. So I created a second account that has administrative permissions, which might have lead me to this problem.

You may receive an "Access is denied" error message when you try to debug a Web application in Visual Studio .NET, and you have administrative permissions -  First search got the job done!
Access Denied on TFS - Stack Overflow - Just looking at other reasons that could have been the cause

Inheriting Apps with MVC

While cleaning up some code in the webconfigs of an MVC application I came across a line of code to which I had no knowledge of and even more so was showing up as an error.  I asked myself was it's purpose and most of all why was the Intellisense saying "The 'inheritInChildApplications' attribute is not allowed."?

How do I allow all users access to one route within a website with integrated auth? - Stack Overflow
Changing ASP.NET web.config inheritance when mixing versions of child applications - Scott Hanselman

All the information can be seen and found in the following links but after looking at the comments you will find the reason behind the shown error. "Be aware that the inheritInChildApplications attribute is not part of the web.config schema (even in VS 2012) so you will get blue squiggles under it with a message of "The 'inheritInChildApplications' attribute is not allowed." It will, however, work correctly…

Penguins Rising: Eliminate render-blocking JavaScript

For the most part I have already done a lot of the work for this and this has always been something in my practice to do. In the past what I have done is render all javascripts at the bottom of the page and all styles at the top inside the header. However with this application and since so much of my code is customized and mineralized, I believe I have a small issue with the Jquery taking up more time than the css to load.

(function () { var script = document.createElement('script'); script.setAttribute("type", "text/javascript"); script.setAttribute("src", "js/jquery-2.0.3.min.js"); document.getElementsByTagName("head")[0].appendChild(script); Resources
Remove Render-Blocking JavaScripts - PageSpeed Insights — Google Developers
HTML script async Attribute - This might have also worked but look at later.javascript - load jquery after the page is fully loaded - Stack OverflowGoog…

At the Start of My C# Research

This article is a list of resources that I used way back at the start of my career with C#. Since there are a lot of C# tutorials already out I just wanted to write out some of my experiences and topics that I was curious to learn when starting out. The main reason why I wanted to used C# for programming was for MVC applications and toward the second year I discovered XNA.
Getting Ready at the Start!
    If you're a Java Developer the using Statement is much like a import and include in C++. Having experience with both languages doesn't hurt and speaking from my own experiences with both languages, C# is probably the easiest compared to all of them. And for multiple reasons, but mostly because of Visual Studio's Intellisense in my opinion. 

C# language itselfRandom resources that I used, for multiple projects.Visual C# ResourcesDelegates Tutorial C# Short Type - Sometimes its just good to compare (Java, C++).Creating Custom Routes : Official Microsoft SiteString …

HTML Select Placeholder

Adding a selected and disabled attribute works as well and doesn't require any javascript, however refreshing the page does not reset the value. Doing a hard refresh does reset the value (for firefox). However there seems to be a placeholder attribute in draft (as of november 2014). "When there is no default option, a placeholder can be used instead". However in the example the placeholder value is still selectable after a choice has been made. This may not be what you want, so combining the two attribute and the javascript below guaranty the behavior I'm looking for. I could even support older browser with a little work.

    The Purpose of this article is to make a placeholder in select that should help prevents bad selections with and make it easier to validate if no selection is made. In this article I will assume you have Jquery and the Jquery Validation plugin installed on your web application and similar html code displayed like the the following...

Flash Videos not in full view for the Chrome Browser

     For a while I had issues with Adobe Flash in the Chrome Browser, immediately my assumption was that I had a incompatibility issue with Adobe Flash. So I started installing older version  of Adobe Flash from11.9.900.170 and back on Window Plateforms. This did not help so I soon started my research which I did not bother to install older versions of Chrome since it had never been a problem before. 
Resources (weren't helpful)

No video in full-screen mode | Flash PlayerAdobe - Flash PlayerAdobe Community: Full Screen Mode is not working for adobe flash playerFull screen mode - YouTube HelpAdobe - Flash Player : Help - Display Settings

My Solution
    Turns out my problem wasn't caused by an update but by me and my playing around with settings. Which I never took into consideration since I don't often watch videos in Flash. If I can help it I will watch Youtube videos in HTML5. Also I was at the time of playing with things look for ways to improve my laptop's speed and …

My Introduction to TeamCity

    The purpose of this article is simply to record and document my experiences using Teamcity. I know later down the road I will have a lot more questions about TeamCity but for now just I wanted to write down what I already know and to describe some of the ways that I use it.

    I first was introduced to TeamCity in June 2013, where it was setup to automate builds and stared builds based the changes in SVN. Using this setup on daily basis, I could see my commits and others as well. Depending on if it was developing or production code teamcity would build code accordingly and put those changes in a Pending state (or Build Queues). Much like TFS, TeamCity allows me to see the history of changes and who has committed what. One thing I liked the most was that TeamCity would not publish builds that failed. Which was a critical step when developing, especially when pushing to prod  since it gave me a quick double check before going live with my code.

Future Questions
     Down the road I…

My Introduciton to Nodejs

Much of the material here is based on the chapter 8 in the book: Programming in HTML5 with Javascript and CSS3 and the Nodes.js site.
Getting started with Nodes.js
"Nodes.js is built on the Google Chrome Javascript runtime""The Platform implements an event-driven, non-blocking I/O model and is lightweight and efficient.""data-intensive,real-time applications that run across distributed devices.""executes your Javascript by using Google's V8 virtual machine"Download Nodes.js and install, need to accept the licensing agreements. 
HelloWorld.jsvar http= require('http') //"http module is a core built-in, low-level module highly optimized."http.createServer(function (request, response) {response.writeHead(200, {'Content-Type':'text/plain'});response.end('Hello World from Nodes.js!\n');console.log('Handled request');}).listen(8080, 'localhost');console.log('Server running at …

MVC Excel Email Attachment with NPOI

    The First Question I had after successfully creating a Excel sheet was how do I create an attachment from a stream? A second to be more specific was how do I add an attachment to an email using System.Net.Mail? Ultimately I wanted to have the Excel Exports in C# using NPOI but I started small and thankfully others had already asked and answered these questions. After which was just a matter of knowing What the correct content-type for excel files was?
First Attempt
MailMessage mail = new MailMessage(); HSSFWorkbook workbook = CreateExcel(OrderId); MemoryStream ms = new MemoryStream(workbook.GetBytes()); mail.Attachments.Add(new Attachment(ms, "example.xls", "application/")); _emailService.SendEmail("", "Email test", "Testing 123"); Changed it to..MemoryStream ms = new MemoryStream(); workbook.Write(ms); This was based on the QA "NPOI - Sending workbook as ema…

MVC Data Exported to Excel with NPOI

This is an article for just writing an Excel file using NPOI and I want the quickest and easiest way to export a excel file from MVC. To keep everything in work fluid motion I will keep the user on the same page and do a forced download within that page. This is a setup that I have seen in multiple times and I think works great in today's modern website designs.

Creates excel files
Leniel Macaferi's blog: Creating Excel spreadsheets .XLS and .XLSX in C#
Create Excel Spreadsheets Using NPOI
var workbook = new HSSFWorkbook(); var ExampleSheet = workbook.CreateSheet("Example Sheet"); var rowIndex = 0; var row = ExampleSheet.CreateRow(rowIndex); row.CreateCell(0).SetCellValue("Example in first cell(0,0)"); rowIndex++; Problems I facedXLS is not the same as CVS which is obvious but truthfully I did not know the difference between the two file types (other than their different extensions). So I asked myself what is the Difference between CSV and XLS files? W…

C# vs. Javascript Foreach

     This article is about a certain style of writing in Javascript that I like use when iterating through an array combined with a foreach which looks something like the following...
var someArray = ["1", "2", "3"]; $.foreach(someArray, function(key, value){ console.log(key + " , " + value); });      Ultimately when I tried to take this same concept over to C# the style did not convert over in the exact same way. I found that the temp variable being used to iterate with did not have any values that tracked where it was in place of the iteration. I found myself asking a similar question in how do you get the index of the current iteration of a foreach loop? To see what I tried you can look at another person's problem where I had attempted in the same manner. Attempting to use the "current" value in the GetEnumerator() sadly does not work.

     To summarize the answer for this problem the "foreach" uses th…

A Static DropDownList for ASP.Net MVC

     When creating a static dropdowns list in MVC, I have a two approaches that I like to commonly use. I know there are many ways to achieve this UI structure and I don't consider either one of the following approaches to be the final solution. However for awhile now I have been using these two approaches and I think they are much simpler and easier to maintain compared to other ways that I have seen. Rather than writing out the HTML select tag and all the options I take advantage of the Html Helper Dropdownlist. I avoid model bind since it is static and I don't want create the list outside of the view. I think this would only create more work to maintain and confusion for other coders if they new to my applications.  I did not come up with either solution completely on my own and I actually forget where I saw them since it did take a while to find these approach in my research.What's important to take away in this article is that if you look carefully you will se… MVC4 - Bundling and Minification

    While this article may be very simple and straightforward, there are a few concepts here I think are important to note. In my next article will be looking more in depth on the idea of creating a customized Web.config, but for now with this article, I just want to look at activating the bundling and minification feature by using the xml tags inside a MVC's Web.config. This feature is only available in ASP.NET 4.5 and above.
The First Problem
With the following inside your Web.config... (transform is with a Captial T.)
And with either of the following inside your build config or customized Web.config (I.E. Web.Release.config)
This also can be achieved by doing the following...
     In both snippets of code you do not need to use the "xdt:Locator" attribute (used only in cases where there are multiples elements of the same name .  What you may not see is that in the Web.config we have the "location" tag wrapped around the "system" tag. This is important …

Updating Razor 2.0 to 3.0 with MVC

    Currently updating an application from MVC 4.0 to MVC 5.0 but before I update MVC I wanted to update the Razor package. Since the MVC package is dependent on the Razor. So this article is about Razor 2 to Razor 3 and the problems I faced.

Razor in my opinion
Razor 3.0 (details in the link) is an awesome package in my opinion and I shudder to think anyone who writes MVC applications using ASPX. For me the Razor syntax is an effective way to write visually clean code and because of this provide very low maintenance.

Issues with Razor Updating from 2.0 to 3.0
As I updated I encounter numerous problem with the Razor package from 2.0 to 3.o and not only did it break my application but destroyed the Intellisense for Razor (mostly for ViewBags).
So for my first problem...
Inheritance security rules violated by type: 'System.Web.WebPages.Razor.WebPageRazorHost'. Derived types must either match the security accessibility of the base type or be less accessible.
Which c…

Checkboxes, Radio and Button Inputs

    The purpose of this post is to think out loud and remind myself the types of inputs available for HTML. Three that I most commonly use are the radio, checkboxes and a input type button (not the button tag). Which are the focus of this article since none of them allow me to achieve what I want.

The UI I want:      I want to give my users a place to select from a group of item and only select one item as well as give them the option to deselect that option if they change their mind of selecting that set of group. This is how the input  check-boxes but without the grouping like a radio button. So really combining the two (radio and check-boxes) types of input together. You have the look and feel of a check-box but the logic of a radio and the add logic of unselecting from a check-box. There are other types of inputs/UI's that I did not look at but this was just a starting point for my research. 
Radio Button     Here is an Example of what a radio button does. As you can see once s…

Sunyit's Project BITS Documentations

The following is a collection of documents that I created solely for myself and colleagues in order to meet standards for implementing a Hadoop cloud service. That said there is a lot of information that is specific for the systems used and customized to only work for those who were apart the project. The objective for Project "Bits" can be found here in this link. All ip addresses have been marked with x's and urls generalized in order to protect the SunyIT network system. I continue to study the systems used here and release the documents in hope that others might take up the project and implement it at his or her's University/College.

Back-Bone of Bits ProjectThis is the server BitsGW which features a vpn connection across multiple colleges. Creating VM’s of BitsHP (hadoop machines) to have a scalable new projects. Also providing a LDAP connection service.BitsGW has the following user: afassett, adminBitsHP: Pxe server for machines behind it for Hadoop nodes. Whi…