火曜日, 8月 03, 2010

The Road To SharePoint Web Parts

The Definitive Hello World Web Part Tutorial

Debugging Web Parts



The Road To SharePoint Web Parts

Creating A SharePoint Web Part Project

Programming With Your SharePoint Web Part

Debugging Your SharePoint Web Part

Microsoft Windows SharePoint Services の Web パーツをパッケージ化および配置する


Page Viwer Webpart - change settings programatically
In the 'webpart.cs' you can write :
// declaration of the PageViewerWebPart
protected Microsoft.SharePoint.WebPartPages.PageViewerWebPart cPreviewPageViewer = new PageViewerWebPart();

and in the RenderWebPart() method :

// link to the page you want / or use a string var of the url
string SiteUrl = ""
cPreviewPageViewer.ContentLink = SiteUrl;
// redim of the pageviewer
cPreviewPageViewer.Height = iFrameHeight.ToString();
// render
cPreviewPageViewer.RenderControl(output);

WSPBuilder (SharePoint WSP tool)

WSPBuilder (SharePoint WSP tool)

A SharePoint Solution Package (WSP) creation tool for WSS 3.0 & MOSS 2007



Adding SharePoint class resources to your feature using WSPBuilder



Connectable Page Viewer Web Part

SharePoint Portal Server 2003 Web パーツと Web コントロール

月曜日, 8月 02, 2010

JBossProperties

JBossProperties

Read a properties file from a class deployed in Jboss?

   1. Properties properties=new Properties(); 
2. properties.load(Thread.currentThread().getContextClassLoader().getResource("app.properties").openStream());



How do I load a properties file from WEB-INF/classes?
For files directly in the classes directory, our code is like:
        Properties dbProps = new Properties();

//The forward slash "/" in front of in_filename will ensure that
//no package names are prepended to the filename when the Classloader
//search for the file in the classpath
InputStream is = getClass().getResourceAsStream("/"+in_filename);
if(null == is)
{
throw new ConfigException("Can't locate file:" +in_filename);
}
try
{
dbProps.load(is);//this may throw IOException
return dbProps;
}
catch (IOException ioe)
{
System.err.println("Properties loading failed in AppConfig");
throw new ConfigException(ioe,"Can't locate file:" +in_filename);
}

Getting the Browser Default Language in PHP

Getting the Browser Default Language in PHP