Saturday, March 27, 2010

Best Job Search Tips – By Alison Doyle

Referred from URL

http://jobsearch.about.com/od/jobsearchtips/a/bestips.htm

Here are the best job search tips from career experts for job seekers who are starting a job search or who want to get their job search moving.

If there's anything on the list that you're not incorporating in your job search, consider giving it a try. Given the job market, it makes sense to include as many different job hunting initiatives as possible in your job search.

Do you have a job search strategy that worked really well for you? Add your job search tip to the list.

Best Job Search Tips

Use Your Cover Letter to Your Advantage. Your cover letter is particularly important. It's the job searcher's opportunity to help the potential employer see that the applicant's skills and experience match what the employer seeks. In the current economic climate, with the scarcity of jobs, a well-written cover letter distinguishes your application.
Susan Heathfield, About.com Guide to Human Resources

Get on Twitter. Use Twitter to demonstrate your professional expertise and draw the attention of people in your industry who will want to hire you. At the same time, actively reach out to those kinds of people by following and networking with industry recruiters and other insiders.
Jacob Share, Job Search Expert and creator of JobMob

Build or Enhance Your Personal Brand. My recommendation to all job seekers would be to focus on building, or enhancing, their personal brand. Attract potential employers to you rather than reaching out to them. That puts job seekers in a much better negotiating position that the reverse, even in a tough economy.
Susan Joyce, President and Editor/Publisher of Job-Hunt.org

Don't be Hunter... Become the Hunted. Hire a personal branding consultant to manage your professional identity such that you become a high priority target for headhunters, recruiters, and HR representatives. Don't fall prey to herd mentality and become just one of many who post resumes online and respond to cold ads. If you manage your personal brand properly you will develop a constant stream of inbound inquiries with regard to new opportunities.
Mike Myatt, CEO Coach, N2growth

Google Yourself. Put positive and branded professional content under your name and Google yourself everyday.
Maor Kaplanski, Personal eBrand & ORM expert, Israel

Start a Blog. It's a fact that companies and organizations are employing social media in the recruiting process, especially to reach their most elusive demographic - Generation Y. To stand out online, you're going to need more than a Facebook or LinkedIn account. So start a blog. Bloggers are the Internet's thought leaders. If you can establish yourself as an online authority in your field, you're a step ahead of other online candidates who are doing the bare minimum.
Ryan Paugh, cofounder, Brazen Careerist, Inc.

Think Outside and Inside the Box. Think outside and inside the Box (that computer screen in front of you, that is). In other words, you need to diversify the way you market yourself, whether it's online at job boards, or at social network sites like Twitter or LinkedIn; or offline at campus recruitment opportunities, job fairs, networking events in your field, or spreading the word to friends. The more ways in which you get the word out that you're looking, the more potential jobs you'll hear about.
Dawn Papandrea, managing editor of The CollegeBound Network, and blogger at CollegeSurfing.com/blog

Rely on Your Professional Network to try and get inside information for future openings or current openings. Of course if you have a LinkedIn profile you will want to ensure your profile is up-to-date and is robust, fully completed, and full of industry keywords that draw attention to your skills and accomplishments. Highlight areas where you can provide added value if you were to be hired.
Linda, Reeder, Training Specialist, LinkedIn

Create a Digital Resume . Hiring managers are looking for validation of skills. A digital resume allows you to incorporate rich-media portfolio items alongside more traditional, text-based resume content. In today's world it is a good idea to establish a professional online profile for consistent presentation of your personal brand that you can link to from anywhere you have a digital footprint - email signature, Facebook, LinkedIn, blog, company website bio, etc. At VisualCV.com you can build (for free) an online resume that you can have public or private that will help you stand out in your job search.
Pierce Resler, Director of Marketing, VisualCV

Use Keywords. Analyze job postings for keywords and incorporate them in your resume. Review at least 6 to 8 job postings in their field to find keywords that appear consistently in these postings. This gives job seekers a good idea of what skills hiring managers are looking for. These are also likely to be the keywords that hiring managers search for when going through their database of resumes. Incorporating these keywords into your resume increases the chances of your resume being seen by a hiring manager.
Cheryl Palmer, Certified Executive Career Coach, Call to Career

Give to Get. The karma of the job search says "What goes around, comes around." If you want to receive something, first you must give something. Freely give your time and talent to others. Give without expectation of getting anything back.
Terrence Seamon, Learning and Organization Development Consultant

Expand your Job Search Resources. Job boards and networks are fantastic - also contact your alumni office, placement office at your college/university, industry associations, professional organizations, read trade journals - all can be great resources for your job search.
Elaine Basham, Partner, The Resume Group

Stay Positive. While there may be times when the job search will leave you feeling frustrated, don't ever give in to negative feelings or let them derail you from your professional goals! The key is to be with someone who is going to reinforce your efforts and give you encouragement and suggestions. This is not the time to be around people who complain or who have a negative outlook.

Sharepoint Tips n Tricks - Part 2

In continuation with earlier post -
Sharepoint Tips n Tricks
1) Check whether a given SPField exist or not before fetching value from it:


string columnValue = string.Empty;
string columnInternalName = string.Empty;
string fieldName = "Myfield";
SPListItem listItem; //Code to get SPListItem

//Check required SPField exist or not
if (listItem.ParentList.Fields.ContainsField(fieldName))
{
//Get internal name of SPField
columnInternalName = listItem.ParentList.Fields[fieldName].InternalName;

//Fetch column value based on internal name
if (listItem[columnInternalName] != null)
columnValue = listItem[columnInternalName].ToString();
}

2) SharePoint 2007 recommended guidelines for managing site collections, site, lists, and documents according to business needs:
· 50,000 site collections per content database
· 500 MB per site collection (default quota maximum)
· 50 MB file size limit (recommended) up to 2 GB (maximum)
· 2000 items per list view
3) Check whether page is in Edit Mode or not


if (Microsoft.SharePoint.SPContext.Current.FormContext.FormMode == SPControlMode.Display)
{
// your code to support display mode
}
else if(Microsoft.SharePoint.SPContext.Current.FormContext.FormMode = SPControlMode.Edit)
{
// your code to support edit mode
}

OR


WebPartManager wp = WebPartManager.GetCurrentWebPartManager(Page);

if (wp.DisplayMode == WebPartManager.BrowseDisplayMode)
btnLink.InnerText = "Edit Page";
else if (wp.DisplayMode == WebPartManager.DesignDisplayMode)
btnLink.InnerText = "Exit Edit Mode";
else
btnLink.Visible = false;

Reference...
http://www.codeproject.com/KB/sharepoint/SwitchWPMode.aspx
http://mystepstones.wordpress.com/2008/09/23/detecting-the-current-mode-displayedit/
4) SPFeature to deploy page in a SharePoint site


Feature.xml
<?xml version="1.0" encoding="utf-8"?>
<Feature Id="f08674ee-2b0e-41aa-8d28-24e788d03c11"
Title="PageDeployment"
Description="Description for PageDeployment"
Version="12.0.0.0"
Hidden="FALSE"
Scope="Web"
DefaultResourceFile="core"
xmlns="http://schemas.microsoft.com/sharepoint/">
<ElementManifests>
<ElementManifest Location="elements.xml"/>
<ElementFile Location="MyPage.aspx" />
</ElementManifests>
</Feature>


Elements.xml
<?xml version="1.0" encoding="utf-8" ?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<Module Name="Pages" Path="" Url="">
<File Name=" MyPage.aspx" Url=" MyPage.aspx" IgnoreIfAlreadyExists="FALSE" NavBarHome="True"></File>
</Module>
</Elements>
 

Code to download document from SharePoint Document Library


Following code snippet demonstrate the way to download a MS Word document (or any file) from SharePoint SPDocumentLibrary-


string siteURL = "http://localhost:80/"; //Write valid site URL
//Get SPSite and SPWeb instance
using (SPSite spSite = new SPSite(sireURL))
{
using (SPWeb spWeb = spSite.OpenWeb())
{
//Get time stamp to download file with unique name
string strFileName = DateTime.Now.ToString("ddMMyyyy_HHmmss");

//Get folder path
string directoryPath =
Path.Combine(Environment.GetFolderPath
(Environment.SpecialFolder.LocalApplicationData),
"MyFolder");

//Create directory if it not exist
if (!(Directory.Exists(directoryPath)))
{
Directory.CreateDirectory(directoryPath);
}

//Get template url
string documentUrl; //Write valid document URL

//Download file in file system
SPFile myFile = spWeb.GetFile(documentUrl);
byte[] binFile = myFile.OpenBinary();

//Generate file name
filename = Path.Combine(directoryPath, strFileName + ".doc");

//Do file write operation
FileStream fs =
new FileStream(filename, FileMode.Create, FileAccess.ReadWrite);
BinaryWriter bw = new BinaryWriter(fs);
bw.Write(binFile);
bw.Close();
}
}

SPFolder related operations in SharePoint

 

1) Get SPListItem(s) of a particular SPFolder


SPList splist;
SPFolder spfolder; //Get the required folder instance
SPQuery spquery = new SPQuery();
spquery.Query = string.Empty;
spquery.Folder = spfolder;
spquery.ViewAttributes = "Scope=\"Recursive\""; //For nested folder structure

SPListItemCollection itemCol = splist.GetItems(spquery)

2) Create a SPListItem based on a custom ContentType or SPFolder ContentType


SPWeb spweb; //get the SPWeb instance
SPContentType myCType = splist.ContentTypes["Custom content type"];
SPList splist = spweb.Lists["My SPList"];
SPListItem splistitem = splist.Items.Add();
splistitem["ContentTypeId"] = myCType.Id;
splistitem.Update();

splistitem["Title"] = "New Item";
splistitem.Update();

3) Add a SPListItem in a particular SPFolder


SPWeb spweb; //get the SPWeb instance
SPContentType myCType = splist.ContentTypes["Custom content type"];
SPList splist = spweb.Lists["My SPList"];
//get folder instance
SPFolder spfolder = splist.Folders[1];
SPListItem splistitem
= splist.Items.Add(spfolder.ServerRelativeUrl
, SPFileSystemObjectType.File, null);

splistitem["ContentTypeId"] = myCType.Id;
splistitem.Update();

splistitem["Title"] = "New Item";
splistitem.Update();
 

Image Preview functionality in SharePoint


Question:
How to display the Image preview without actually uploading the file in SharePoint?
Solution:
To check the image preview we can temporary move/place the file in Layout folder. Then pass URL in following format to Image control:
"/_layouts/images/MYFOLDER/MyImageName.jpg
After checking the Image preview and final upload of image file, we can delete the temporary image file from 12 hive.
Code snippet (comments are self-explanatory):


FileUpload FileUploadImage; //FileUpload control to select image file
Image myImage; //Image control to be used for preview functionality

//Getting 12 hive path through SPUtility.GetGenericSetupPath() function
string folderPath =
Microsoft.SharePoint.Utilities.SPUtility.GetGenericSetupPath("TEMPLATE")
+ "\\IMAGES\\MYFOLDER\\";

//Check folder path
if (!Directory.Exists(folderPath))
Directory.CreateDirectory(folderPath);

//Copy the image file to a temporary folder in 12 hive
File.WriteAllBytes(folderPath + FileUploadImage.FileName,
FileUploadImage.FileBytes);

/* //File.Copy() will not work in case of remote image upload
File.Copy(FileUploadImage.PostedFile.FileName,
folderPath + FileUploadImage.FileName, true);
*/

//Set the URL of image control
myImage.ImageUrl =
"/_layouts/images/MYFOLDER/" + FileUploadImage.FileName;


Note: In a similar manner we can preview media file (like *.wmv) before actual upload in SharePoint.



Custom RSS Feed in SharePoint

SharePoint provides SPList’s level RSS Feed url [SPList Toolbar > Actions > View RSS Feed].
http://<server-name:port>/_layouts/listfeed.aspx?List=List_GUID
In above URL by specifying List’s GUID we can get feeds for all records (irrespective of any SPView or of Default View).
Now consider a scenario where we want SPView specific feeds.
In File System, ListFeed.aspx file is placed at following:
C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\LAYOUTS\ListFeed.aspx
ListFeed.aspx refers Microsoft.SharePoint.ApplicationPages.ListFeed.cs class file. Using Reflector we can get the idea that ListFeed.aspx can accept 3 query strings as parameters: List GUID, Meeting Instance ID and View GUID.


Guid guid = new Guid(base.Request.QueryString.GetValues("List")[0]);
string[] values = base.Request.QueryString.GetValues("InstanceID");
string g = base.Request.QueryString["View"];

ListFeed.cs is using following function to get the feeds:


base.spList.WriteRssFeed(base.Response.OutputStream,
base.meetingInstanceId, this.spView);

MSDN Description of WriteRssFeed function:


public void WriteRssFeed (
Stream outputStream,
int meetingInstanceId,
SPView spView
)

Parameters
outputStream : A Stream object that represents the document stream.
meetingInstanceId : An integer value that represents the meeting instance.
spView :An SPView object that represents the view.
WriteRssFeed supports 3 overload methods:
SPList.WriteRssFeed(Stream) :
Writes the RSS feeds from the list to the specified document stream.
SPList.WriteRssFeed (Stream, Int32) :
Writes the RSS feeds from the list that are associated with the specified meeting to the specified document stream.
SPList.WriteRssFeed (Stream, Int32, SPView) :
Writes the RSS feeds from the list that are associated with the specified meeting and view to the specified document stream.
So if we want View specific feed then we have to specify all 3 parameters, but here comes the issue: what does Meeting Instance ID mean and from where we get this value?
Now to get the SPView specific feed, we can write custom RSS Feed. I referred this post- blah.winsmarts.com. I modified the original code little bit. I created a application page and instead of writing inline server code I created a class library so that I can debug the page.
HTML Code:


<%@ Page Language="C#"
Inherits="MyNameSpace.MyFeed,MyNameSpace,
Version=1.0.0.0,Culture=neutral,PublicKeyToken=1d5ac09ccd41620f" %>

C# Code:


using System;
using System.Web;
using System.Text;
using Microsoft.SharePoint;
namespace MyNameSpace
{
public class MyFeed
: Microsoft.SharePoint.WebControls.UnsecuredLayoutsPageBase
{
public void Page_Load()
{
try
{
Response.Write(GetRSSFromListView(
Request.QueryString["List"],
Request.QueryString["View"]));
}
catch (Exception ex)
{
Response.Write("<pre>");
Response.Write(ex.ToString());
Response.Write("</pre>");
}
}
private static string GetRSSFromListView(string strListGUID,
string strViewGUID)
{
StringBuilder sb = new StringBuilder();
sb.Append("<?xml version=\"1.0\"?>");
sb.Append("<rss version=\"2.0\">");

using (SPSite site = new SPSite(SPContext.Current.Web.Url))
using (SPWeb web = site.OpenWeb())
{
SPList list = web.Lists[new Guid(strListGUID)];
SPView view = null;
if (strViewGUID != null)
view = list.Views[new Guid(strViewGUID)];
else
view = list.DefaultView;

sb.Append("<channel>");
AddTag("title", list.Title, sb);
AddTag("description", list.Description, sb);

SPListItemCollection items = list.GetItems(view);
foreach (SPListItem item in items)
{
sb.Append("<item>");
AddTag("title", item["LinkTitle"].ToString(), sb);
AddTag("link", list.RootFolder.Url
+ "/DispForm.aspx?ID=" + item.ID, sb);
sb.Append("<description>");
foreach (string viewField in view.ViewFields)
{
if (viewField != "LinkTitle")
{
AddTag(
viewField.Replace("_x0020_", " "),
HttpContext.Current.Server.HtmlEncode
(item.GetFormattedValue(viewField)),
sb);
}
}
sb.Append("</description>");
sb.Append("</item>");
}
sb.Append("</channel>");
sb.Append("</rss>");
}
return sb.ToString();
}


private static void AddTag(string tagText,
string tagValue, StringBuilder sb)
{
sb.Append("<");
sb.Append(tagText.Replace(" ", "_"));
sb.Append(">");
sb.Append(HttpContext.Current.Server.HtmlEncode(tagValue));
sb.Append("</");
sb.Append(tagText.Replace(" ", "_"));
sb.Append(">");
}
}
}

Now if we use the above custom RSS Feed page URL and pass it to SharePoint’s out-of-box RSS Viewer Webpart, then we will get following error:
The RSS webpart does not support authenticated feeds.
Solution -
Changing to Kerberos authentication
1. On the Central Administration page, click Application Management.
2. Under the Application Security section, click Authentication Providers.
3. Click the Default provider, and change Integrated Widows authentication from NTLM to Negotiate (Kerberos).


















Thursday, March 11, 2010

Status Reports

Reference URL

http://herdingcats.typepad.com/my_weblog/2010/03/status-reports.html?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+typepad%2FHerdingCats+%28Herding+Cats%29&utm_content=Google+Reader

This is a topic near and dear to my heart, along with many others. Brad has a nice list of items that should be in a status report.

  1. Project title
  2. Project description
  3. Contact information for key project personnel
  4. Quick view high-level status on project, budget, and schedule
  5. Recent tasks completed
  6. Tasks in progress
  7. Upcoming tasks
  8. Status of all change requests
  9. Detailed budget status
  10. Issues status
  11. Risks status

Here's my experience in a variety of project domains, ranging from Enterprise IT, heavy construction, defense and space, industrial projects, and other domains.

Fundamental Reason for a Status Report

A status report should do just what it says - report the status of the project. So what are the primary elements of the project status?

  • Are we on schedule?
  • Are we on budget?
  • Are the deliverables we said we would deliver compliant with their technical performance measures?
  • Do we have all we need to stay on budget, on schedule, and meet the technical performance requirements?
  • Do we know the risks and do we have a plan to mitigate or retire them?

This is the status of the project.

Here's the real problem with Status Reports

Status reports should report progress to plan. Tasks and the execution of tasks are not measures of progress. The production of deliverables are the measure of progress. So Brad's list of tasks in progress, upcoming tasks, and completed tasks are no measures of progress.

This is a common mistake of confusing effort with results. "We're completing all these tasks, so we must be making progress."

It's results that measure progress, not the effort.

So the status report must state in clear and concise terms, what results were accomplished during the period of measurement. But not just any results, but the Planned Results. So this means we must know what results were planned. This means we must have a Plan. A Plan that says what is "planned" to be accomplished.

Wednesday, March 3, 2010

App.config for C# Library

In case you are providing a dll which needs to make use of the entries in the app.config, they have to be added in the app.config of the final project in which your dll will be added as reference.


Say for example, your dll will be used in the TestApplication project, then the entries needed by your dll will go into the app.config of the TestApplication.


So don't worry abt the app.config attaching with the dll..