Wednesday, September 21, 2011

String Trim in Javascript

function TrimAll(sString)
{
    while (sString.substring(0,1) == ' ')
    {
        sString = sString.substring(1, sString.length);
    }
    while (sString.substring(sString.length-1, sString.length) == ' ')
    {
        sString = sString.substring(0,sString.length-1);
    }
    return sString;
}

Controlling Browser Properties with JavaScript - History Lesson



Controlling Browser Properties with JavaScript - History Lesson



As you travel from one Web site to another, most browsers record the URLs you visit in a history buffer, allowing you to return to them at any time with a single click. This history buffer is accessible to you via the History object, which exposes methods and properties for moving forward and backward through the list of recently-accessed URLs.
In order to access the last URL in the, you would use the history.back() method (equivalent to hitting the browser's "Back" button),


<script language="JavaScript">
// go back
window.history.back();
</script>



while the history.forward() method lets you access the next URL in the history list (equivalent to hitting the browser's "Forward" button).


<script language="JavaScript">
// go forward
window.history.forward();
</script>



Here's an example which illustrates how these two methods can be used to build a simple navigation toolbar:


<form>
<input type="button" name="back" value="Back"
onClick
="javascript:history.back();">
<
input type="button" name="next" value="Forward"
onClick
="javascript:history.forward();">
</form>



You can obtain the total number of items in the history list through the History object's "length" property, as below:


<script language="JavaScript">
// display number of items in history list
alert(history.length);
</script>



You cannot access the elements of the history list directly. You can, however, tell the browser to go to a particular URL from the history list with the history.go() method, which accepts an offset indicating which URL in the history list to go to. In this system, the current URL is always 0, meaning that you can go one step back with the following code:


<script language="JavaScript">
// go back
window.history.go(-1);
</script>



Which is equivalent to the following:


<script language="JavaScript">
// go back
window.history.back();
</script>

Monday, September 12, 2011

All Government office related links

All government office related links are available... Kindly save it ......

This section provides you with information and useful links to avail various Citizen Services being provided by the Central & State/UT Governments in India . The list, however, is not exhaustive, as we are committed to adding more and more information about other services for which citizens and other stakeholders need to interact with the Government. Keep visiting this section for new updates !!
Obtain:
Apply for:
Register:
Check/Track:
Book/File/Lodge:
Contribute to:
Others:
Search for Available Services Select from the menu to know the available Services contributed by Central Government Ministries/Departme nts, State Government, UT.
Central: [Select Central \/]
[RichText]
State: [ Select State \/]
[ Search State ]
Advance Search <http://www.india.gov.in/howdo/advancedsearch.php>

Recently Added Online Services
Tamil Nadu: Online application of marriage certificate for persons having registered their marriages <http://www.india.gov.in/howdo/onlineservice_detail.php?service=2691>
Source: National Portal Content Management Team Error! Filename not specified.
Global Navigation



Friday, May 20, 2011

Sunday, May 15, 2011

Wednesday, May 4, 2011

Saturday, April 30, 2011

Difference between Biztalk 2006 to Biztalk 2009

Installing BizTalk Server 2010 on WindowsServer 2008 R2 and 2008

What Are the BAM WCF and WF Interceptors

Business Activity Monitoring (BAM) is a collection of tools, APIs, and services that allow you to manage aggregations, alerts, and profiles, and to instrument automated processes to send events to monitor relevant business metrics. Together, these provide end-to-end visibility into business processes and enable you to stay abreast of business process status and results.


BAM interceptors extend this same functionality into Windows Workflow Foundation (WF), Windows Communication Foundation (WCF), and other runtime environments. By using a BAM interceptor, you can track your business processes without recompiling your WF or WCF solution—integration is done through a configuration file.

By using the BAM WF or WCF interceptor in your project, you can:
  • Use the BAM portal to view information about the business processes running in your WF or WCF application.
  • Use BAM functionality without adding additional code to your application.
  • Deploy your solution using familiar BizTalk Server tools and utilities.
  • Leverage your existing BizTalk Server environment for existing and new WF and WCF applications.


 

Difference between call by out and call by reference

out = ref -  (intiliazation)

void main()
{

int x,y,o,r;

//ref
r=0;
MultiMath(x,y,ref r);
MultiMath(x,y,out o);

}



functions

OUT
private int MultiMath(int a, int b, out o)
{
    o = a*b;
return a+b;
}

REF
private int MultiMath(int a, int b, out r)
{
    r = a*b;
return a+b;
}

http://www.c-sharpcorner.com/UploadFile/5eae74/6867/

Friday, April 29, 2011

WCF Workflow Service Application Enpoint configuration

 IService is a WCF Workflow Service Application Servicecontarct



<?xml version="1.0" encoding="utf-8" ?>
<configuration>
    <system.web>
        <compilation debug="true" targetFramework="4.0" />
    </system.web>
    <system.serviceModel>
        <services>
   <service name="xxxxxxx">
       <host>
           <baseAddresses>
               <add baseAddress="http://xxxxxx:1231/Configuration/"/>
           </baseAddresses>
       </host>
    <endpoint address="BDSIBUP301.xamlx"
     binding="wsHttpContextBinding" contract="IService" />
    <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
   </service>
  </services>
        <behaviors>
            <serviceBehaviors>
                <behavior>
                    <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
                    <serviceMetadata httpGetEnabled="true"/>
                    <!-- To receive exception details in faults for debugging purposes, set the value below to true.  Set to false before deployment to avoid disclosing exception information -->
                    <serviceDebug includeExceptionDetailInFaults="false"/>
                </behavior>
            </serviceBehaviors>
        </behaviors>
        <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
    </system.serviceModel>
    <system.webServer>
        <modules runAllManagedModulesForAllRequests="true"/>
    </system.webServer>
</configuration>

Saturday, March 12, 2011

Introduction to Biztalk Business Rule Engine Facts

What is fact ?

Facts are discrete pieces of information about the world.  Facts can originate from many sources



Facts are discrete pieces of information about the world. Facts can originate from many sources (event systems, objects in business applications, database tables, and so on), and must be fed into the Business Rule engine in BizTalk Server by using one of the following elements:

Fact types.
  • .NET objects (methods, properties, and fields)

  • XML documents (elements, attributes, and document subsections)

  • Database rowsets (values from table column)

In the Business Rule Composer, you can use the Facts Explorer to browse and bring data into your rules from various sources.

.Net objects
In the Business Rule Composer, you can specify a .NET assembly as a data source

 Engine control functions

  This Engine control functions are allow the application or policy to control the facts in the rule engine's working memory.

Engine controlf functions are

Assert

Retract

RetractByType

Reassert

Update

Halt


Assert
Assertion is  the process  of adding object isntances into Business Rule engine's working memory.


The following table summarizes the assert behavior for the various types, showing the number of resulting instances created in the engine for each asserted entity, as well as the type that is applied to each of those instances to identify them.
Entity Number of instances asserted Instance type
.NET object1 (the object itself)Fully Qualified .NET Class
TypedXmlDocument1-N TypedXmlDocument(s): Based on Selector bindings created and document contentDocumentType.Selector
TypedDataTable1-N TypedDataRow(s):
One for each DataRow in the DataTable
DataSetName.DataTableName
TypedDataRow1 (the TypedDataRow asserted)DataSetName.DataTableName
DataConnection1-N (one for each TypedDataRow returned by querying the DataConnection)DataSetName.DataTableName




Retract:
You can use the Retract funciton to remove objects form the Business rule engine's working copy.

RetractByType
The RetractByType funciton retracts all instances of a specified type in the working memory, where as the Retract function retracts only specific items of a certain type.


Reassert

To reassert means to call the Assert function on an object that is already in the engine's working memory.

Update
When Update function is invoked an object, the object is reasserted into the engine to be re-evaluated, based on the new data and state.

 Halt
You can use the Halt function to halt the current rule engine execution. The Halt function takes one parameter of type Boolean. If you specify the value for the parameter as true, the rule engine also clears the agenda that contains the pending candidate rules.


http://en.wikipedia.org/wiki/Rete_algorithm


Friday, February 11, 2011

Basic Activity Designer WWF4.0

ActivityDesigner
(System.Workflow.ComponentModel.Design)

Activitydesigner is a class it provides a simple designer which lets the user visually design activities in the design mode.

ActivityDesigner provides a simple mechanism for the activities so they can participate in rendering the workflow on the design surface.


Activitydesginer class provides following designer features.


Rendering support by drawing icons, description, border, interior, and background.
  • Rendering help text.
  • Default glyphs required by designers.
  • Filtering design-time-specific properties.
  • Default event generation.
  • Default hit testing.
  • Triggering validation.
  • Tool-tip support.
  • Participation in keyboard navigation.
  • Accessibility support.
  • Toolbox support.
  • Theme support.
  • Smart tag support.
  • Message filtering support.
  • Event handling for mouse events.


Activity designers that support creating activities that have children—composite activities—must inherit from the CompositeActivityDesigner class in the System.Workflow.ComponentModel.Design namespace.

The CompositeActivityDesigner class provides the following designer features:

Expanding and collapsing the designers.
Drag-and-drop indicators.
Layout of self and child activities.
Drawing self and child activities.
Hit testing the child activities.
Inserting and removing activities from a hierarchy.

Following are different types of activitydesginers

reference from msdn


 
 




Tuesday, January 18, 2011

Threading

Trheading :

AutoResetEvent allows threads to communicate with each other by signaling. Typically, this communication concerns a resource to which threads need exclusive access.
A thread waits for a signal by calling WaitOne on the AutoResetEvent. If the AutoResetEvent is in the non-signaled state, the thread blocks, waiting for the thread that currently controls the resource to signal that the resource is available by calling Set.