Today I read another god article about JQuery selector tutorial. Here is a link for that. Two great articles about JQuery in one day, amazing !!!
Happy Programming !!!
Chirag Darji
ASP.NET Consultant & Trainer
Today I read another god article about JQuery selector tutorial. Here is a link for that. Two great articles about JQuery in one day, amazing !!!
Happy Programming !!!
Chirag Darji
ASP.NET Consultant & Trainer
Posted in DotNet 2.0, DotNet 3.0, Javascript, Techincal | 7 Comments »
Today while reading about JQuery I came across really helpful and well narrated article about JQuery Selector, JQuery Event Binding and use this key word in JQuery by Elijah Manor. You can read it here.
Happy programming !!!
Chirag Darji
ASP.NET Consultant
Posted in DotNet 2.0, DotNet 3.0, Javascript, Techincal | Tagged Dotnet, JQuery | Leave a Comment »
While analyzing Payroll management system, I came across an interesting question that how can we find second and fourth Saturday of every month. As in India we still do not have five days a week in most of organization, bad humm……:( . Most of organizations offer only second and fourth Saturday off. Below is the code to find particular day of week and its occurrence in given month and year,
/// <summary>
/// Returns date for specific week day and its occurrence in month.
/// </summary>
/// <param name="DesiredDay">Perticular day of week, System.DayOfWeek</param>
/// <param name="Occurrence">Its occurrence, System.Int32</param>
/// <param name="Month">Month, System.Int32</param>
/// <param name="Year">Year, System.Int32</param>
/// <returns></returns>
private int GetDateForWeekDay(DayOfWeek DesiredDay, int Occurrence,int Month,int Year)
{
DateTime dtSat = new DateTime(Year, Month , 1);
int j = 0;
if (Convert.ToInt32(DesiredDay) - Convert.ToInt32(dtSat.DayOfWeek) >= 0)
j = Convert.ToInt32(DesiredDay) - Convert.ToInt32(dtSat.DayOfWeek) + 1;
else
j = (7 - Convert.ToInt32(dtSat.DayOfWeek)) + (Convert.ToInt32(DesiredDay) + 1);
return j + (Occurrence - 1) * 7;
}
Fig – (1) Code to find Second Saturday and Fourth Saturday of Month.
Happy Programming !!!!
Chirag Darji
ASP.NET Consultant & Trainer
Posted in DotNet 2.0, DotNet 3.0, Techincal | 8 Comments »
Last week I installed Microsoft Dynamic 4.0 on my virtual machine and I found that it will be helpful for beginner like me, if there is a step by step installation guide. Lets start with OS selection.
1. You can use Windows Server 2003 or later server version. I had Windows Server 2003 R2.
2. Install latest service pack for OS you installed.
3. Install Internet Information Service.
4. Install Active Directory.
5. Configure DNS Server.
6. Create new user for domain and make him member of Administrators group.
7. Install SQL Server 2005 with Reporting Service and Analysis service.
8. Configure new account as service account for Report Server and Analysis server.
9. Install Visual Studio 2008.
10. Start installation of CRM 4.0
11. Enter display name for your Organization.
12. Next step is to select installation path, you can leave this as it is or select specific folder,
13. Next select website for CRM, I choose new website with different port address in my case it was 5555 as shown in image below,
14. Next you need to enter URL for Reporting server.
15. Next you have to select Organization Unit. Click on Browse button and select the root node of your domain in my case it is chirag.
16. On next step you need to specify security account, choose the one you created in step 6. Enter the password in password textbox and click next.
17. Select your local machine as Email Router setting or select specific machine on domain which you are using at email server. I chose my local machine so localhost.
18. Once you click next you will see System Requirements screen. If Domain user, SQL Server Reporting Service and ASP.NET are installed properly you will receive no error or warning else you will receive error message. I received following errors,
19. If you receive error message for SQL Server or SQL Server Reporting Service don’t be afraid. Open Services from Start – All Programs – Administrative Tools – Services. Check whether SQL Server Agent is running. If not right click on service and select property. Select Startup Type as Automatic and click on start button.
20. Another common error is for Indexing service. Follow the steps mention in point 19 to start Indexing Service.
21. You can see a warning mentioning Verify Domain User account SPN for the Microsoft Dynamics CRM ASP.NET Application Pool account. This will usually shows when you add specific domain account for security account in step 16. You can solve this warning now or after installation by following steps mentioned at http://billoncrmtech.blogspot.com/2008/08/now-i-am-master-tips-for-running-crm-40.html
22. If System Requirements screen show no error or warning on next step installation will be started.
23. Finally you will see following screen, this means your CRM is installed.
Happy Programming !!!!
Chirag Darji
ASP.NET Consultant & Trainer
Posted in CRM, DotNet 2.0, DotNet 3.0, Javascript | 8 Comments »
I was playing with different date format in SQL Server as need to display date in YYYY-MM-DD HH:MI:SS.MMM format. I knew there is a CONVERT function which can do this however I did not have the exact parameter value to convert my date to mentioned format. I got really use full chart on internet which provides different option and parameter value for CONVERT function. For my case syntax is
SELECT CONVERT(nvarchar(23),GetDate(),121)
You can check complete table here.
Happy Programming !!!!
Chirag Darji
ASP.NET Consultant & Trainer
Posted in Techincal | 3 Comments »
In my recent project I need to identify all columns on which full text index is created. You can find that in management studio from Database – Storage – Full Text Catalogs and right click on catalog name and select property. It display all tables and columns as shown below,
Fig – (1) All columns on which full-text index is created.
An alternative is to use query to find all columns on which full-text index is created.
SELECT tbl.[Name] TableName,clm.[Name] ColumnName FROM
Sys.Tables tbl INNER JOIN Sys.Columns clm
ON tbl.[object_id] = clm.[object_id]
INNER JOIN sys.fulltext_index_columns fic
ON clm.[column_id] = fic.[column_id]
WHERE tbl.[Type] = ‘U’
Happy Programming !!!!
Chirag Darji
ASP.NET Consultant & Trainer
Posted in DotNet 2.0, DotNet 3.0, Sql Server, Techincal | Leave a Comment »
Today while working in SQL Server 2008, I encounter an interesting problem which does not allow me to change design of any table in particular database. Each time when I try to change table columns or resize the I receive following message,
Saving changes is not permitted. The changes you made require following tables to be dropped and re-created. You have either made changes to a table that can’t be recreated or enabled the option prevent saving changes that require the table to be re-created.

Fig – (1) SQL Server 2008 – Saving changes is not permitted
You will receive this message when you restore database created on other server. SQL Server 2008 by default prevent changes for database which are created on another server by enabling “Prevent saving changes that require table re-creation” from Tools – Options.
Fig – (2) Solution – SQL Server 2008 – Saving changes is not permitted
To solve this go to Tools – Options and uncheck “Prevent saving changes that require table re-creation” option.
Happy Programming !!!
Chirag Darji
Posted in Sql Server, Techincal | 6 Comments »