Search This Blog

Monday, January 5, 2015

UpdatePanel control

The UpdatePanel control is probably the most important control in the ASP.NET AJAX package. It will AJAX'ify controls contained within it, allowing partial rendering of the area. We already used it in the Hello world example, and in this chapter, we will go in depth with more aspects of the control.

The <asp:UpdatePanel> tag has two childtags - the ContentTemplate and the Triggers tags. The ContentTemplate tag is required, since it holds the content of the panel. The content can be anything that you would normally put on your page, from literal text to web controls. The Triggers tag allows you to define certain triggers which will make the panel update it's content. The following example will show the use of both childtags.

1. AsyncPostBackTrigger

it is the one which enforces Asynchonous post back of the Page.., i.e. the AJAX way. The data will be transacted without full post back. When you are using functionalities like login, you may use this.

Ex. You are having two dropDowns Viz., Countries and States. the states should be loaded when a country is selected and it should be changed on Countries change.

You may use AsyncPostBackTrigger in this scinario., which will populate the states ddl without full post back.

2. PostBackTrigger

It is the one which does not follow the AJAX functioalities., but the full post back as usually(as Without using UpdatePanel). Situtions are there where you would not like to enforce Partial Post back (as explained in Point 1. above). Like you are having FileUpload Control withing the UpdatePanel and when you do it by AsyncPostBack, you will not get any values to the server. It requires Full PostBack. in such a case you should use this trigger.

thank you.

Have you ever wonder which country is the best to live for IT engineers?

Below a list of 10 best countries to live for software engineers.

10. Canada
I. Median annual pay for software engineer – $57500

II. Position in the world ranking of “Happiness Index – experienced well-being” - 2

III. Position in the ranking of  “Best for workers: Countries” – 11

9. New Zealand
I.Median annual pay for software engineer – $59600

II.Position in the world ranking of “Happiness Index” - 17

III.Position in the ranking of  “Best for workers: Countries” – 8

8. Sweden
I. Median annual pay for software engineer – $61400

II. Position in the world ranking of “Happiness Index” - 5

III. Position in the ranking of  “Best for workers: Countries” – 8

7. Germany
I. Median annual pay for software engineer – $63800

II. Position in the world ranking of “Happiness Index” - 27

III. Position in the ranking of  “Best for workers: Countries” – 20

6. Australia
I. Median annual pay for software engineer – $65900

II. Position in the world ranking of “Happiness Index” - 8

III. Position in the ranking of  “Best for workers: Countries” – 14

5. Israel
I. Median annual pay for software engineer – $70700

II. Position in the world ranking of “Happiness Index” - 10

III. Position in the ranking of  “Best for workers: Countries” – 10

4. Denmark
I. Median annual pay for software engineer – $71500

II. Position in the world ranking of “Happiness Index” - 1

III. Position in the ranking of  “Best for workers: Countries” – 4

3. United States
I. Median annual pay for software engineer – $76000

II. Position in the world ranking of “Happiness Index” - 16

III. Position in the ranking of  “Best for workers: Countries” – 7

2. Norway
I. Median annual pay for software engineer – $81400

II. Position in the world ranking of “Happiness Index” - 3

III.Position in the ranking of  “Best for workers: Countries” – 6

1. Switzerland
I. Median annual pay for software engineer – $104200

II. Position in the world ranking of “Happiness Index” - 6

III.Position in the ranking of  “Best for workers: Countries” – 24

For more: Click here

Friday, January 2, 2015

error: $Resources:core,ImportErrorMessage

Today i have faced an exception while importing webpart into a wiki page.

error: $Resources:core,ImportErrorMessage

we can overcome this issue.

Solution : Visual Studio -> Build -> Select 'Retract' -> Clean solution -> Build and deploy.

If it doesn't  solve this please check your connection string name is correct or not. it may cause the issue.


thank you.



Thursday, December 25, 2014

5 Exciting Reasons to Work for a Tech Startup in India

Today fresh graduates really have a choice whether to work in a startup or not. 10 years ago this was not a viable option for most people.

Becoming a tech entrepreneur yourself is a great career option too. But in this post we will look at the pros and cons of working in an early stage tech startup vs. working in a well established IT organization like Infosys, HCL or Accenture.

Now i am working in a startup.

From my experience, here are some of the reasons why you should work in a startup.

1. Massive Learning

The amount of things that you learn by working in a startup is probably twice or thrice than that of a big organization with 1,000+ employees. The startup I am working for had only 30 employees but we were getting a lot of things done at a breakneck speed. I was blown away by the possibility of how much a small team can create given such less time and resources.

There are less formalities, less boring meetings, less approvals and more ownership and freedom for what you are doing. Due to less friction, you end up doing more work and hence you learn more in a shorter period of time.

2. Work Satisfaction

Big corporates are famous for their dirty politics. I am not saying that everyone is bad in such firms, of course there are a lot of visionary leaders in big companies but your chances of bumping into a bad manager are relatively high.
Many times, you do a piece of work and someone else takes credit for it. You want to do something creative, but your manager doesn’t allow it because he/she is afraid that you would overshadow him.

Since startups have a small team, everyone knows what kind of work you do and you will get valued. (On the flip side the only way to look like a hard worker is by working hard!)

New ideas and initiatives are encouraged and there will not be a need to get formal approvals to do new things. As a developer if you think that adding a small tweak to the user interface will help your customers, you can just inform your team and go ahead with it. You may not get a monetary reward for it, but your customers will be happy and that would give you immense pleasure.

Whether you work in the development team, marketing team or customer support, there are plenty of opportunities to talk and meet with your customers. You will see how your work is adding value to your clients. This motivates you to go the extra mile to serve them. In the process you will learn what entrepreneurship is and what value creation really means. Yes, you are really making the world a better place by doing your part of the work.

3. People & Culture

Except a few, most of the startups have a great work culture. Startups do not waste energy in unnecessary things such as insisting on formal dress codes, having to follow up with minutes of meetings, minimum clock-in hours at the office, leave policy and so on.

All that matters is the work you do. How much value you add to the organization and hence to its customers. Mostly it wouldn’t be a big deal if you wear t-shirts, come late to the office, made a spelling mistake in your email, didn’t adhere to the HR policy while taking a leave and so on. I don’t say all startups are like that, but most startups don’t have time to make an issue about small things that do not matter.

In startups people around you are more like a family than co-workers. There are mostly no politics and deception because no one has time to play such games.

4. A Platform to become an Entrepreneur

If you have ever dreamed of becoming an entrepreneur, working in a startup is the best place to get started. Since startups are small and mostly transparent in what they do, you will learn a lot more about the business in a holistic manner.
If you join a very big organization, you most likely will have no idea about the needs of the customer, the price they are willing to pay for your solution and whether your work has really solved their problem.

You work, you get paid and the only thing your will learn is how to save yourself from getting blamed when something goes wrong. This will help you only if you want to climb the corporate ladder.

But for people like you & me who believe in doing the work, corporate politics is a dirty game to play and the chances of becoming a senior manager or VP in an organization with tens of thousands of employees is very less.
Again, I am not here to give a bad rap about big and well respected organizations. Apart from my own experience, I have a lot of friends working in such firms and it looks like I have a fair idea about how things are in such companies. I am sure you will agree with me on this.

In a startup, you will do a little bit of everything when some important things have to be done on time. I am working mostly in developing but when the need arose, I did a bit of design, a bit of customer support and a bit of installation too. Such experience is priceless when you want to start your own company some day.

Another big benefit of working in startups is that you will network with great people. You will become friends with the CEO and co-founders. If you add good value and move on, no one is going to get angry at you that you are leaving them and will be more than happy to help with when you run your own startup with their contacts, resources and experience.

5. Remuneration & Stock Options

There is a misconception that Indian startups don’t pay well. If you do your homework, you will find out that if you are well educated, intelligent, hardworking and have the right attitude, a 5 year work experience could get you double or triple the salary compared to a traditional IT company in India. If the take home salary is not that much, you will be compensated with stock options of equivalent value.

You will get stock options which is usually in the range of 0.05% to 0.5% with startups which are a few years old. For startups that are less than 1 year old, you may get 5% to 10% stock but in that case you will be more of a co-founder than an employee.

0.5% may not look like much. But imagine you are working in a company that is valued at 10 Crores when you join. 0.5% of that is 5 Lakhs. This may not look like much in the beginning. But startups grow very fast and within a few years your company can become a 100 crore company.

If the startup is acquired, your 5 Lakhs becomes 50 Lakhs and that could be more than enough to fund your own startup or take a mini-retirement.

Redbus.in had an exit at 800 crores approx. An employee who had a 0.5% stock would have cashed out 4 crores when Redbus was acquired by South African Naspers group. An employee who only had a 0.05% stock would still have cashed out 40 Lakhs! Such exits don’t happen often but you have to consider the possibilities.

The Downsides
 You cannot have a cake and eat it too. Roses come with thorns. For some people working in a startup is not the right thing

Here are the down sides:

-- There is a bit of risk that your startup could fail and your stock options will becomes worthless. But you would still come out with priceless learning and experience.
-- The amount of work involved in startups is higher. Sometimes you may have to work on weekends as well. Sometimes more than 12 hours on a weekday. Startups are for people who want to work hard, not for people who want to look like working hard and take home a paycheck every month.
-- You may not work in a fancy looking office building in a tech park. Your relatives may not have heard of the company you work for. You may not get opportunities to travel abroad. Sometimes you may not even have A/C in your office. Startups are for people who want to learn more and get more things done, not for people who want to settle in a job with comfort.

Conclusion
If the downsides do not bother you, I am sure by now you are excited to work in a startup!

Difference between Black Box Testing and White Box Testing.


             Black Box Testing
                   White Box Testing
1
Black box testing is the software testing method which is used to test the software without knowing the internal structure of code or program.
White box testing is the software testing method in which internal structure is being known to tester who is going to test the software.
2
This type of testing is carried out by testers.
Generally, this type of testing is carried out by software developers.
3
Implementation Knowledge is not required to carry out Black Box Testing.
Implementation Knowledge is required to carry out White Box Testing.
4
Programming Knowledge is not required to carry out Black Box Testing.
Programming Knowledge is required to carry out White Box Testing.
5
Testing is applicable on higher levels of testing like System Testing, Acceptance testing.
Testing is applicable on lower level of testing like Unit Testing, Integration testing.
6
Black box testing means functional test or external testing.
White box testing means structural test or interior testing.
7
In Black Box testing is primarily concentrate on the functionality of the system under test.
In White Box testing is primarily concentrate on the testing of program code of the system under test like code structure, branches, conditions, loops etc.
8
The main aim of this testing to check on what functionality is performing by the system under test.
The main aim of White Box testing to check on how System is performing.
9
Black Box testing can be started based on Requirement Specifications documents.
White Box testing can be started based on Detail Design documents.
10
The Functional testing, Behavior testing, Close box testing is carried out under Black Box testing, so there is no required of the programming knowledge.
The Structural testing, Logic testing, Path testing, Loop testing, Code coverage testing, Open box testing is carried out under White Box testing, so there is compulsory to know about programming knowledge.


For more: Click here

Highest Paying Programming Languages You Should Learn

Computer programming has quickly become one of the most lucrative industries in the United States. In fact, the average salary for a computer programmer just hit an all-time high as it approaches $100,000. But, there are some languages and skill sets that are more valuable than others, and Quartz has compiled some data to break down these differences.
Quartz's Max Nisen pulled out some figures on the most valuable programming languages based on a larger study from the Brokings Institution that was published in July.

Based on that data, here are programming languages listed next to their average annual salary from lowest to highest:

12. PERL - $82,513

11. SQL - $85,511

10. Visual Basic - $85,962

9. C# - $89,074

8. R- $90,055

7. C - $90,134

6. JavaScript - $91,461

5. C++ - $93,502

4. JAVA - $94,908

3. Python - $100,717

2. Objective C - $108,225


1. Ruby on Rails - $109,460


While some of these coding languages can help you earn around $100,000, train to become a Salesforce Architect if you want one of the highest paying jobs in tech. According to data from IT recruiting firm Mondo that was published back in March, Salesforce Architects can earn anywhere between $180,000 and $200,000.

For more: Click here

Unit Testing

DEFINITION

Unit Testing is a level of the software testing process where individual units/components of a software/system are tested. The purpose is to validate that each unit of the software performs as designed.


A unit is the smallest testable part of software. It usually has one or a few inputs and usually a single output. In procedural programming a unit may be an individual program, function, procedure, etc. In object-oriented programming, the smallest unit is a method, which may belong to a base/super class, abstract class or derived/child class. (Some treat a module of an application as a unit. This is to be discouraged as there will probably be many individual units within that module.)

METHOD

Unit Testing is performed by using the White Box Testing method.

When is it performed?

Unit Testing is the first level of testing and is performed prior to Integration Testing.

Who performs it?

Unit Testing is normally performed by software developers themselves or their peers. In rare cases it may also be performed by independent software testers.

TASKS

Unit Test Plan
  • Prepare
  • Review
  • Rework
  • Baseline
Unit Test Cases/Scripts
  • Prepare
  • Review
  • Rework
  • Baseline
Unit Test
  • Perform
BENEFITS

  • Unit testing increases confidence in changing/maintaining code. If good unit tests are written and if they are run every time any code is changed, the likelihood of any defects due to the change being promptly caught is very high. If unit testing is not in place, the most one can do is hope for the best and wait till the test results at higher levels of testing are out. Also, if codes are already made less interdependent to make unit testing possible, the unintended impact of changes to any code is less.
  • Codes are more reusable. In order to make unit testing possible, codes need to be modular. This means that codes are easier to reuse.
  • Development is faster. How? If you do not have unit testing in place, you write your code and perform that fuzzy ‘developer test’ (You set some breakpoints, fire up the GUI, provide a few inputs that hopefully hit your code and hope that you are all set.) In case you have unit testing in place, you write the test, code and run the tests. Writing tests takes time but the time is compensated by the time it takes to run the tests. The test runs take very less time: You need not fire up the GUI and provide all those inputs. And, of course, unit tests are more reliable than ‘developer tests’. Development is faster in the long run too. How? The effort required to find and fix defects found during unit testing is peanuts in comparison to those found during system testing or acceptance testing.
  • The cost of fixing a defect detected during unit testing is lesser in comparison to that of defects detected at higher levels. Compare the cost (time, effort, destruction, humiliation) of a defect detected during acceptance testing or say when the software is live.
  • Debugging is easy. When a test fails, only the latest changes need to be debugged. With testing at higher levels, changes made over the span of several days/weeks/months need to be debugged.
  • Codes are more reliable. Why? I think there is no need to explain this to a sane person.

TIPS

  • Find a tool/framework for your language.
  • Do not create test cases for everything: some will be handled by themselves. Instead, focus on the tests that impact the behavior of the system.
  • Isolate the development environment from the test environment.
  • Use test data that is close to that of production.
  • Before fixing a defect, write a test that exposes the defect. Why? First, you will later be able to catch the defect if you do not fix it properly. Second, your test suite is now more comprehensive. Third, you will most probably be too lazy to write the test after you have already fixed the defect.
  • Write test cases that are independent of each other. For example if a class depends on a database, do not write a case that interacts with the database to test the class. Instead, create an abstract interface around that database connection and implement that interface with mock object.
  • Aim at covering all paths through the unit. Pay particular attention to loop conditions.
  • Make sure you are using a version control system to keep track of your code as well as your test cases.
  • In addition to writing cases to verify the behavior, write cases to ensure performance of the code.
  • Perform unit tests continuously and frequently.

ONE MORE REASON

Lets say you have a program comprising of two units. The only test you perform is system testing. [You skip unit and integration testing.] During testing, you find a bug. Now, how will you determine the cause of the problem?

Is the bug due to an error in unit 1?
Is the bug due to an error in unit 2?
Is the bug due to errors in both units?
Is the bug due to an error in the interface between the units?
Is the bug due to an error in the test or test case?

For more: Click here


Restricting Custom People Picker to only one Sharepoint group programatically

Refer the following script files in your page,     <!-- For People Picker -->     <script type="text/javascript" src...