Pages

Tuesday, July 27, 2010

SharePoint 2010 Meeting Workspaces and Blogs are not MUI enabled

A while ago I wrote about the new multilingual capabilities of SharePoint 2010 based on the Multilingual User Interface (MUI) – see Multilingual User Interface (MUI) in SharePoint 2010 – Part I and Multilingual User Interface (MUI) in SharePoint 2010 – Part II. But beware – apparently not all site definitions support the MUI.

If you try to enable alternate languages for a SharePoint 2010 meeting workspace you will get an error stating “this site is based on a template that does not not support alternate languages”.

Now if you want to find out which webtemplates support MUI you can run the following Powershell script:

$siteUrl = "http://hades/"
$site = get-spsite $siteurl

$site.GetWebTemplates("1033") |foreach {Write-Host $_.Title $_.Name  $_.SupportsMultilingualUI;}

you will get a listing of all installed webtemplates within thesite collection specified by the url parameter. Notice the SupportsMultilingualUI property of the SPWebTemplate object – for the Meeting Workspaces and Blog site definitions this will return False.

Next is the complete listing returned on an install with SharePoint Server 2010 Enterprise Edition.

Global template GLOBAL#0 True
Team Site STS#0 True
Blank Site STS#1 True
Document Workspace STS#2 True
Basic Meeting Workspace MPS#0 False
Blank Meeting Workspace MPS#1 False
Decision Meeting Workspace MPS#2 False
Social Meeting Workspace MPS#3 False
Multipage Meeting Workspace MPS#4 False
Central Admin Site CENTRALADMIN#0 True
Wiki Site WIKI#0 True
Blog BLOG#0 False
Group Work Site SGS#0 True
Tenant Admin Site TENANTADMIN#0 True
Access Services Site ACCSRV#0 True
Assets Web Database ACCSRV#1 True
Charitable Contributions Web Database ACCSRV#3 True
Contacts Web Database ACCSRV#4 True
Issues Web Database ACCSRV#6 True
Projects Web Database ACCSRV#5 True
Document Center BDR#0 True
(obsolete) Records Center OFFILE#0 True
Records Center OFFILE#1 True
Shared Services Administration Site OSRV#0 True
PowerPoint Broadcast Site PowerPointBroadcast#0 True
PerformancePoint PPSMASite#0 True
Business Intelligence Center BICenterSite#0 True
SharePoint Portal Server Site SPS#0 True
SharePoint Portal Server Personal Space SPSPERS#0 True
Personalization Site SPSMSITE#0 True
Contents area Template SPSTOC#0 True
Topic area template SPSTOPIC#0 True
News Site SPSNEWS#0 True
Publishing Site CMSPUBLISHING#0 True
Publishing Site BLANKINTERNET#0 True
Press Releases Site BLANKINTERNET#1 True
Publishing Site with Workflow BLANKINTERNET#2 True
News Site SPSNHOME#0 True
Site Directory SPSSITES#0 True
Community area template SPSCOMMU#0 True
Report Center SPSREPORTCENTER#0 True
Collaboration Portal SPSPORTAL#0 True
Enterprise Search Center SRCHCEN#0 True
Profiles PROFILES#0 True
Publishing Portal BLANKINTERNETCONTAINER#0 True
My Site Host SPSMSITEHOST#0 True
Enterprise Wiki ENTERWIKI#0 True
Basic Search Center SRCHCENTERLITE#0 True
Basic Search Center SRCHCENTERLITE#1 True
FAST Search Center SRCHCENTERFAST#0 True
Visio Process Repository visprus#0 True

 

CustomErrors setting in SharePoint 2010 for debugging purposes

On a SharePoint 2010 development machine you typically want to see the full stack trace when an error occurs. In SharePoint 2010 you will need to modify 2 web.configs:

  • Underneath “[systemdrive]:\inetpub\wwwroot\wss\virtualdirectories\<port>”
  • In the layouts directory underneath the SharePoint root directory or 14 hive – “[systemdrive]:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS

The settings that you need to change are still the same:

  • Change Debug=”true”
  • CallStack=”true”
  • CustomErrors=”Off”

Happy SharePointing …

Friday, July 23, 2010

WP7 SqliteClient with transaction support

I've updated the preview and implemented the transaction-commit-rollback mechanism.
For 1050 rows the results are:

Without transaction: 13.088 sec
Using transaction: 0.474 sec

For more rows you will get even better results.

The link to the project is the one from the previous post

Enjoy the update

NAMASTE

Tuesday, July 20, 2010

WP7 SqliteClient Preview

WP7 developer devices are already out in the US and I still hope I will qualify for one here in Italy. I would really love to test one. Brandon PLEASE don't forget me :)
As my proposal was a better port of the Sqlite engine I did some optimizing on the engine and also implemented/adapted a SqliteClient that is easier to use than normal sqlite3 commands.
At the "engine" part I use the journal file persistent this way the engine doesn't delete and create the journal at each command. I've also eliminated SQLITE_DEBUG from conditional compilation symbols spares some temporary file access.
For the client at the beginning I've wanted to compile the System.Data and Sqlite class from Monotouch, but after looking a little bit at the source code I've realized that there are tons of things that doesn't make sense on WP7. I wanted to keep it simple and searching I've found the SqliteClient.cs written by Frank Krueger for Monotouch. I've adapted the class to run with our library and got a pretty nice result.
I've also improved the test project and now you are able to set how many rows will be inserted, select the inserted rows and see the elapsed times for insert/select commands. For the insert I've tested two methods: the first with prepare, step, finalize and the second one with sqlite3_exec (which should be the same) and the insert time are more or less the same.



Anyway it's only a preview as it was not intensively tested and because it can be improved. If some of you find ways to optimize the library please let me know and I will post it for everybody. Also let me know what you think.


Here you have the link to the source code

NAMASTE

Sunday, July 18, 2010

WP7 IsolatedStorage speed improvement



If you remember some time ago I did some tests on the IsolatedStorage and the speed was not very impressive (it was 127 slower than the FileStream). In the new beta version there is a TREMENDOUS improvement. I rerun the old test in the new emulator and these are the results:

Dividing the two values 0.0632/1.1866=0.0532 which is almost the same with FileStream. At this point it does make sense implementing/porting a database engine on IsolatedStorage. Well done WP 7 Team on this aspect.


NAMASTE

Friday, July 16, 2010

Compact Framework Network Printing

As usual a lot of time without posting but I had no time. I am really excited about the beta tools of WP7 (2 days ago I felt asleep while installing the beta cause the only time I have is after 11 p.m.). I also did some improvements on the Sqlite port but I will post it as soon as it will be usable (I plan to compare the performance with Perst even if it's a different approach).
I am posting this because I lost almost two days and maybe someone that needs it will find it right away. My task was some labeling process using MC9090 devices and Zebra S4m printers. I decided to go for in-memory parameterized forms. The client application uses two method for connecting to the printer:
1) Some of the printers have ethernet port and it is quite simple to communicate with the printer as you will open a socket to 9100 port and send the commands to the printer. This is simple
2) Other printers are connected as shared printers from pc's. This one should also be simple but it gave me a lot of headaches and mainly from my fault. I have two approaches:

a. The classic one that you would also do on Windows applications is to invoke CreateFile with the UNC name of the shared printer. My mistake with this approach was that I set the main window as TopMost and when calling the CreateFile windows mobile it will pop up a networking window where you have to insert the user name and password to use for authentication (this even if Guest access is enabled on the shared printer). So this approach was working but as I did not see the pop up window I thought it doesn't work

b. The second one is a little bit more complex. I am invoking WNetAddConnection3 to map the printer as a local resource (when using this method you can also pass the username and the password) and than using CreateFile on the local resource. After sending everything to the printer I call WNetCancelConnection2 to remove the resource (not really optimized but works). The second one seems more stable

The only annoying thing in this moment is the POCKET PC networking pop-up that tells me that the job has finished printing. I want to disable it (I think that it's something to do with the registry) but didn't find the way yet.

I am attaching 2 files Print.cs and Networking.cs. Print.cs has two methods one with authentication and another without.

Hope someone will find it useful


Namaste