Monday, May 19, 2008

Change GridView backgrod color

aspx

< id="grdLicensedClients" runat="server" onrowdatabound="grdLicensedClients_RowDataBound">

c#

protected void grdLicensedClients_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
DataRowView drv = (DataRowView)e.Row.DataItem;

string areaCode = drv["Area"].ToString();

if (_duplicateAreaCodes.Contains(areaCode))
{
e.Row.BackColor = System.Drawing.Color.Yellow;
}
}
}

Monday, February 25, 2008

Reset IIS and Async service, batch file

iis and async service restarted



.

Saturday, February 23, 2008

Friday, January 4, 2008

Wednesday, January 2, 2008

VPC August 2007 Networking Settings

screenshot



External access from a virual enviroment.

Monday, December 17, 2007

Automatically complete a task via a callout

Code:

public void CompleteTask(Guid taskId)
{
SetStateTaskRequest tr = new SetStateTaskRequest();

tr.EntityId = taskId;
tr.TaskState = new TaskState();
tr.TaskState = TaskState.Completed;
tr.TaskStatus = -1 ; // Set this field to -1 to have the platform set the appropriate value

service.Execute(tr);
}


Unfortunately for some unknown reason; completing the task using the above code will cause the workflow (a Sales Process workflow was tested) to end.

Wednesday, December 12, 2007

Prevent a form from being saved

Javascript - OnSaved() event



Actually it's:

event.returnValue = false;
return false;

What aborts the Save operation.
.