Using sharepoint designer to build workflow can be the faster way to achieve yr workflow objective.
However, the drawback is that you cant deploy it into multiple list / document library
This link will give u a better overview on how to leverage on sharepoint designer to create workflow.
Wednesday, September 23, 2009
Wednesday, September 16, 2009
how to enable debugging mode
lIf you did customization on SharePoint before, you will encounter the case where you have no clue on how to debug your application.
You can turn on the debug mode by changing the below setting in web.config
1. CallStack="true"
2. customerrors mode="Off"
3. compilation debug="true" batch="false"
You can turn on the debug mode by changing the below setting in web.config
1. CallStack="true"
2. customerrors mode="Off"
3. compilation debug="true" batch="false"
Tuesday, September 8, 2009
How to change theme when new site is created
Some of you have this requirement to create a new theme for your customer. And obviously this theme will be used automatically if a new site is created.
One of the stupid way is to include the step to change the theme as part of the operating mannual, but let me show you the tricks.
If you understand the concept of branding on how to change the .master page, you will find this theme changer feature is very similar.
What you need to do is to :
1. Create a new theme (i.e. NewTheme) and put it in 12hive\ Themese folder
2. Create a new .vb file which inherit SPFeatureReceiver and override FeatureActivated method to include the below coding.
Dim objWeb As SPWeb
objWeb = properties.Feature.Parent
objWeb.ApplyTheme ( " NewTheme " )
objWeb.Update()
3. The above is to ensure that newtheme is being switched when the code is feature is activated.
4. Compile it with strong name and deploy to GAC.
5. Package this .dll as feature
6. Locate the onet.xml for site template that you have 12hive\template\sitetemplates\SITE NAME\xml
7. locate to include the feature ID which you have created earlier.
The idea of this theme changer is very similar to branding.
One of the stupid way is to include the step to change the theme as part of the operating mannual, but let me show you the tricks.
If you understand the concept of branding on how to change the .master page, you will find this theme changer feature is very similar.
What you need to do is to :
1. Create a new theme (i.e. NewTheme) and put it in 12hive\ Themese folder
2. Create a new .vb file which inherit SPFeatureReceiver and override FeatureActivated method to include the below coding.
Dim objWeb As SPWeb
objWeb = properties.Feature.Parent
objWeb.ApplyTheme ( " NewTheme " )
objWeb.Update()
3. The above is to ensure that newtheme is being switched when the code is feature is activated.
4. Compile it with strong name and deploy to GAC.
5. Package this .dll as feature
6. Locate the onet.xml for site template that you have 12hive\template\sitetemplates\SITE NAME\xml
7. locate
The idea of this theme changer is very similar to branding.
Wednesday, July 15, 2009
SharePoint RSS
SharePoint RSS provides the flexibility to expose view as RSS feed. With this feature, we can perform filtering, grouping and etc. to aggregate the list data information in the list and expose it as RSS feed.
Follow this article to achieve it.
Follow this article to achieve it.
Tuesday, July 14, 2009
Survey on Publishing template for anonymous
You might experience access denied behaviour when you try to use anonymous access to response survey.
How this happen is because a feature called ViewFormPagesLockDown is activated for publishing site.
So the key is to deactivate this.
stsadm -o deactivatefeature -name ViewFormPagesLockDown -url yrURL
find out more from here
How this happen is because a feature called ViewFormPagesLockDown is activated for publishing site.
So the key is to deactivate this.
stsadm -o deactivatefeature -name ViewFormPagesLockDown -url yrURL
find out more from here
Wednesday, July 8, 2009
Good Architect for DAL
I came across a very structure way to populate data from database back to object class.
After we retrieve data from database, typically we will have a datareader object. We can leverage on the method below to convert dr value to match with the data type in object class.
protected T GetDataObjectValue(IDataReader dr, string columnName)
{
int i = dr.GetOrdinal(columnName);
if (!dr.IsDBNull(i))
return (T)dr.GetValue(i);
else
return default(T);
}
Next, we can build a function to load the value into object class like below:
obj.ID = base.GetDataValue(dr, "ID");
If required, we can add the object into a object List.
After we retrieve data from database, typically we will have a datareader object. We can leverage on the method below to convert dr value to match with the data type in object class.
protected T GetDataObjectValue
{
int i = dr.GetOrdinal(columnName);
if (!dr.IsDBNull(i))
return (T)dr.GetValue(i);
else
return default(T);
}
Next, we can build a function to load the value into object class like below:
obj.ID = base.GetDataValue
If required, we can add the object into a object List.
Thursday, July 2, 2009
Subscribe to:
Posts (Atom)