12.31.2007

12.06.2007

Multi Content Type And Office 2003

Around this month, our project need to provide a multi-content types in a document library for special department. The requirements from user include a. add description property at folder item , b. add seceral property at document and c. embed a permission control column at document item.
After analysis and design, I create two content type for the requirements and do it in test env.
And the problem is Office 2003. When your client computer using Office 2003 and try to new a document from document library, then save it, you will see a pop up window for select content type with "Script Error" message several time...But it is no any problem by using Office 2007.
After touch with Microsoft, we confirm this is a bug and have not hot-fix or patch till now.
Maybe it would fix this problem in SP1, maybe not.
But my user using Office 2003, what can I do? Finally, I remove the content type's default document template, and then only can upload the file when click "new" in action menu...
For all the function workable, but we can smell of the necessary to upgrade Office...
Here is the reference links:
http://forums.microsoft.com/TechNet/ShowPost.aspx?PostID=2071300&SiteID=17
http://207.46.236.188/MSDN/ShowPost.aspx?PostID=2105089&SiteID=1
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2483030&SiteID=1

9.26.2007

Multi Email Accounts in Access Requests Text Box

SharePoint 2007 provides a function for denied user to request access right by email. You can configure an email account for receive the request mail. Just go to "People and Groups", click “Site Permissions", then click "Settings" and choose "Access Requests".

There are not always only one people manage the site, maybe two or more. You can put the ";" between emails in the text box like (owner1@teamsite;owner2@teamsite), then the request mail will send to multi email address.

SharePoint 2007 提供了一個功能讓沒有權限存取某個網站的使用者可以透過Email的方式對該網站請求存取權. 你可以在 "People and Groups"中點選 "Site Permissions", 然後選取"Settings"->"Access Requests". 會有一個Text Box, 填入Email, 就可以收到使用者的請求.

但是一個Site並不一定只會有一個人在管理, 所以怎麼將多人都放入Email清單中呢? 很簡單, 只要把分號放置其中, 像(owner1@teamsite;owner2@teamsite), 這樣子裡面每個人都會收到要求授予權限的Email了.

9.19.2007

Server Error 2041 Occurred Invalid BlogId Parameter

如果使用Windows Live Writer Beta時要Publish新的Post時, 跳出這個錯誤訊息,你可以先看看自己用的是不是最新版, reference here:http://windowslivewriter.spaces.live.com/blog/cns!D85741BB5E0BE8AA!926.entry?&thisPost=cns!D85741BB5E0BE8AA!926&nextComment=true&commentPH=cns!D85741BB5E0BE8AA!952&expand=cmt

或是先確定自己的在Weblog->Edit Weblog Settings裡面的路徑要設定成http://yourweblogname.spaces.live.com/ 的樣子.

If popup up the error message "Server Error 2041 Occurred Invalid BlogId Parameter" after publish new post to "Live Space" by Windows Live Writer, please reference here:http://windowslivewriter.spaces.live.com/blog/cns!D85741BB5E0BE8AA!926.entry?&thisPost=cns!D85741BB5E0BE8AA!926&nextComment=true&commentPH=cns!D85741BB5E0BE8AA!952&expand=cmt

If your version is lastest version, please check the url setting in "Weblog->Edit Weblog Settings", the path should be like http://yourweblogname.spaces.live.com/

SPFieldUser

SPFiled一直都是個難解的東西, 真希望能有Class Diagram與Architecture出來看看.

想到以前想要取出List裡面的Item的Contact or something else的欄位, 用SPUser接了半天只接到Exception...

後來發現要用SPFieldUser去套那個欄位, 然後用SPFieldUserValue去接, 接出來後在SPFieldUserValue.User裡面去取出SPUser.

不過講到這裡, 這裡是有關GetFieldValue的寫法...

String currentvalue=item[field.Title].ToString();

SPFieldUserValue fieldvalue=(SPFieldUserValue)field.GetFieldValue(currentversion);

7.18.2007

This item cannot be deleted because it is still referenced by other pages

根據Chris說法 裡面的Option 4, 我們可以在ASPX中加上我們自己的ASCX(User Control), 這一部分我們可以把他綁在Custom Master Page中, 這個是可行的方案.

接下來我們可以根據Heather說法, 把Custom Master Page綁到Feature中, 然後安裝. 這一部分也是可行的.

以上的動作我會在下一篇中根據我的經驗做一個詳細的介紹.

但是當你把Custom Master Page掛上去後, Activate後, 當你想要更動了, 怎麼辦, 這一部分只好倒著做.

1. 把所有有套用Custom Master Page的Site都換成Default Master Page.
2. Deactivate Custom Master Page.
3. Using stsadm to uninstall the custom master page feature, as follow, stsadm -o uninstallfeature -name [CUSTOMMASTERPAGE]
4. Maybe u got some error message, just using -force.

按照正常的狀況, 接下來我們就可以修改Feature, 再上一次.

但世事總與人願違, 你會發現, 新的feature套不太上去!!! What happen?

當在上面Step 4的時候, 你可以到曾經套用過Custom Master Page的Site看看, 你會發現就算你把Feature卸了下來, 然而Custom Master Page還在List中, 所以才會新版的套不太上去!
怎麼辦, 殺掉應該可以了吧!

但是不管你在SharePoint Site 還是 SharePoint Designer, 你都殺不掉它, 錯誤訊息就是

"This item cannot be deleted because it is still referenced by other pages".

找了KB, 你會發現KB926812好像有說明, 但是等你照做, 你會了解他只是規避問題, 藏起來....這不是掩耳盜鈴嗎?

幸好 Johntimney 有找到方法, 還真神奇的方法, 居然是用SharePoint Designer開個新Folder, 把Custom Msater Page移過去, 整個Folder砍掉, 打完收工.

MOSS, 再次讓我見證了神鬼莫測的一面阿!

7.16.2007

Politician

好個打對台

這是在回家的途中看到的,也不知道是故意的還是不小心的, 居然這麼生硬的安插在旁邊.

感覺上右邊就是挨打的.

不過挨不挨打這對於選舉來說, 真的很難講.

這個整個故事是這樣的, 右邊的看板是"江連福"先生的, 看板主要是說他當立法委員, 努力爭取國道四號 連接到太平, 大里發包施工. 左邊的看板則是"馮定國"先生的, 針對右邊的看板做出糾正.

說穿了就是功勞是誰的的問題.

不過這些案子都是建設案, 台灣的基礎建設案+立法委員, 嗯, 這倒是個好問題.

後來晚上看電視很無聊之餘, Google了一下 , 還真是樂趣無窮.

5.15.2007

email a link

The day, my user in office found a special problem when using SharePoint 2K7 and Outlook 2K7.

The story as below:

User create a new share document library and put a file in there, than click the item's menu, select "Send To" -> "Email a link". Than, popup out an outlook mail dialog with an link to the document. Now, the url isnot work, why? because the domain name of SharePoint contain with some special character, my case is dash.

Per this discussion about this problem, the only way to solve this problem is change domain name...=_=

I will check this problem in Microsoft Connect, I thought this should be one of bug.

5.09.2007

Windows cannot access the specified device, path, or file. You may not have the appropriate permissions to access the item

I am get this information when I want to install VSTS SP1 in windows 2K3. Why I need to install the VSTS in Windows 2K3, that's because I want to develop a program that refer to Windows SharePoint Service 3.0 Tools to VS 2005 extension. Windows SharePoint Service 3.0 Tools to VS2005 extension ONLY can install in the machine that installed SharePoint Service … so silly.

So, the message base on the conditions: Windows 2K3 R2, VSTS 2005, want to install VSTS 2005 SP1.
The error message: as title.

Process: First, I search Microsoft KB and google to find the resolution. Here is the best discussion list about this problem.
First is the digital signature and second is the problem with permission.

But, after I do as both url, I could not resolve the problem still. Moreover, I could not see the ACCESS DINED in the tool mention by second url.

After 4 hours, I find something that I forget to check….
As the the picture below, just so easy to click and every thing is going find.
Just “unlock” the file.

1.06.2007

萬巒豬腳

這次綠島行回程是走南迴回台北, 經過萬巒的時候跑去吃豬腳, 到了台中跑去吃向日葵豬排飯, 豬腳真的不錯吃, 不過除了豬腳, 其他的東西就讓我後悔點, 尤其是虱目魚肚湯...湯清到沒魚味...鹹蛋苦瓜我是不清楚客家人是不是都這樣煮的, 但是一堆苦瓜跟形狀大塊到不行鹹蛋好像就是希望你一口苦瓜一口鹹蛋再一口飯的吃法似的...還是台北的餐廳弄得好吃.
至於向日葵豬排, 老闆好像身體不好, 那天剛好有開張...要去吃的朋友記得先打通電話. 至於味道就不多講了.
這是豬腳跟鹹蛋苦瓜的圖:
From 20070101跨年綠島行3/4

From 20070101跨年綠島行3/4