Wednesday, January 28, 2009

ASP.Net MVC RC1 is available now

Hi all,

Long time waiting for this new baby,ASP.Net MVC (Model View Controller) RC1 is available now to download,and the final release will be there soon,this is a big SHIFT for all web developers.

New Architecture design for our web application will be implemented using this new pattern,i suggest if you didn't know enough information about Model View Controller Pattern,see below link :

http://www.c-sharpcorner.com/UploadFile/napanchal/MVCDesign12052005035152AM/MVCDesign.aspx

once you understand the purpose and the use of it for your enterprise project,here you can see the new features for RC1:

http://weblogs.asp.net/scottgu/archive/2009/01/27/asp-net-mvc-1-0-release-candidate-now-available.aspx

Happy times with .Net

Regards,
Mostafa arafa

Thursday, January 22, 2009

Update Lists in SharePoint using web services

Hi,

I got the following email from a developer,it says as follows:
"
Hello Moustafa. I don't want to bother you, but I've been searching for examples of MOSS 2007 Web Services development, and I have not found anything. I have this situation. There is a document library with some items on it. I need to edit some properties of a document (on that doc libr) from an Office application, using the MOSS web services. I need to change the Title and the Category of that document, but I don't know how to do that. Could you help me please, with an example that could guide to me how to do that? ( If you have some interesting links or something about MOSS 2007 development (using web services or api) I'm going to thank you so much ). Regards ...
------------------------------------------------ Ing. José Mauricio Molina Pérez

"

He wants to update Document Library which is a list using sharepoint web services, and he has a windows application which will invoke this web serivce to update document information,Here you go :

http://msdn.microsoft.com/en-us/library/ms440289.aspx

If you want a useful site for sharepoint developers :
http://www.microsoft.com/click/SharePointDeveloper/


Hope this helps.


Regards,
Mostafa arafa

Friday, January 16, 2009

New Edition of Patterns and Best Practices Application Architecture Guide

Hi Folks,

New Edition V2.0 has been released from patterns and best practices application architecture Team,This Guide is very important for Architect & senior Designer and Developer who are building and design Complex Enterprsie Projects and Application using .Net Technology.

The book is showing the following:
1) Different patterns for design your applications (Web,Mobile,RIA).
2) Layering and Tiers in .Net.
3) SharePoint LOB Applications.
4) How to build Services using different technologies in .Net.
5) Deployment scenarios in .net.

Download link:
http://www.codeplex.com/AppArchGuide/


I recomment every one to read it to follow the best practices and avoid common pitfalls in your design.

Regards,
Mostafa arafa

Wednesday, January 14, 2009

3 Tier Architecture Using VS.Net 2008

Hi All,

I had delivered a session on How to build "3 Tier Architecture Applications Using .Net" and i have uploaded my presentation and my demo project on the following link:

1) Presentation:
http://cid-4bc94054914a6469.skydrive.live.com/self.aspx/Blog%20Code/3LayerArchitectureUsingdotNet011209.pptx

2) Demo Solution contains 3 Layer Asp.Net website and 3 Tier Asp.net Web Application:
http://cid-4bc94054914a6469.skydrive.live.com/self.aspx/Blog%20Code/EAADemos.zip

Hope this helps.

Regards,
Mostafa arafa

Friday, January 09, 2009

Cookies in Asp.net - An Important Tip

Hi folks,

In this post i want to show how to create a cookie in asp.net page which contains a counter ,This counter will be increased every time you visit the page.

The tip which i want to highlight here-(I got this question from one of my firends),That when you try to update the cookie value in asp.net you have to update the expiry date of the httpcookie object,otherwise the asp.net will store the default value which is : 1/1/0001,which let your code to create a cookie every time instead of update the counter value in the cookie file.

The code to do this on page_load event in C# :


if (Request.Cookies["counter"] != null)
{
HttpCookie coo=Request.Cookies["counter"];
int x = int.Parse(coo.Value);
x += 1;
coo.Value = x.ToString();
coo.Expires = DateTime.Now.AddDays(7);// if you omit this line,the cookie will be created each time.

Response.Cookies.Add(coo);
Response.Write(coo.Value);
}
else
{
HttpCookie coo = new HttpCookie("counter", "0");
coo.Expires = DateTime.Now.AddDays(7);
Response.Cookies.Add(coo);
Response.Write(coo.Value);
}



The code for this post is uploaded here:
http://cid-4bc94054914a6469.skydrive.live.com/self.aspx/Blog%20Code/CookiePageTest.aspx.cs


Hope this helps.

Regards,
Mostafa arafa