English:
I just found a video comparing installation of Microsoft Hyper-V and VMWare ESXI.
Indonesian:
Ada yang mau mencoba Microsoft Hyper-V atau VMWare ESXI? Temukan caranya Hyper V side-by-side comparison.
English:
I just found a video comparing installation of Microsoft Hyper-V and VMWare ESXI.
Indonesian:
Ada yang mau mencoba Microsoft Hyper-V atau VMWare ESXI? Temukan caranya Hyper V side-by-side comparison.
English (versi bahasa Indonesia)
One of my team asked me why should we use “List={GUID}” and/or “ID={ItemID}” in query string? Can’t we use other query string name?
My answer is yes you can use other query string name, but you will lost one of out of the box functionality. Why? Because when you keep with standar “List” or “ID” query string then you don’t need to parse it anymore – then SharePoint provides simple way to get SPList or SPListItem object using SPContext.
The query string “List={GUID}” has corresponden SPContext.List , and query string “List={GUID}&ID={ItemID}” has the corresponden SPContext.Item. SPContext.List is SPList and SPContext.Item is SPListItem that can be obtained easily if you follow the convention.
So, check your code now.
-o0o-
Indonesia (see English version)
Ada pertanyaan dari salah satu tim saya kenapa kita harus menggunakan “List={GUID}” dan/atau “ID={ItemID}” di dalam query string? dan apakah kita tidak boleh menggunakan nama lain untuk query string?
Jawabannya adalah tentu saja kita dapat menggunakan nama lain, tetapi kita akan kehilangan salah satu fungsi yang sudah disediakan oleh SharePoint. Mengapa?
Karena jika kita tetap menggunakan standar “List” atau “ID” didalam query string, maka kita tidak perlu melakukan parsing parameter lagi. Dan untuk itu SharePoint telah menyediakan cara yang sangat mudah untuk memperoleh object SPList atau SPListItem dengan menggunakan SPContext.
Query string “List={GUID}” memungkinkan kita untuk memperoleh SPContext.List , dan query string “List={GUID}&ID={ItemID}” memungkinkan kita untuk memperoleh SPContext.Item. SPContext.List adalah objek SPList dan SPContext.Item adalah objek SPListItem yang dengan mudah diperoleh hanya jika kita mengikuti konvensi tersebut.
Jadi, coba cek lagi apakah sudah mengikuti konvensi yang berlaku?
English (versi bahasa Indonesia)
For anyone who customize SharePoint using SharePoint Designer, I believe you’ve familiar with “Error page has been modified”. The reason is obvious, you open the page in browser while modifying it using SharePoint Designer. Then save the page withing SharePoint Designer and try to access any links in that page. So, just go back , refresh and the link will works again.

But how about in a case that this happened in production environment, where nobody edit the page behind the screen. What can cause “Error page has been modified” ?
I have tried some resources from internet and check whether this can help me solve the problem:
1. One or more feature is missing (http://forums.technet.microsoft.com/en-US/sharepointgeneral/thread/9a98188b-9dec-4d85-b8b7-47ba41e5271f/)
2. Use of PublishingLayoutsPage instead of TemplateRedirectionPage (http://blogs.msdn.com/tejasr/archive/2008/06/19/resolution-moss-this-page-has-been-modified-since-you-opened-it-you-must-open-the-page-again.aspx)
3. Use of NLB with affinity set to none (http://support.microsoft.com/kb/892348)
4. Some says that security enhancement in MOSS SP1 (KB936984) /WSS SP1 (KB936988)help to fix this problem.
But unfortunatelly I come back with no luck, untill I read an article “The evil’s of RunWithElevatedPrivilege from Danniel Larson”. I believe that since it drops down to the thread identity, then the current session in page is no longer valid with the links. Thus creating exception “Error page has been modified”. Then, I instructed my team to change all impersonation method to use
SPUserToken sysToken = SPContext.Current.Site.SystemAccount.UserToken;
using(var systemSite = new SPSite(SPContext.Current.Site.ID, sysToken))
{
using (var sysWeb = systemSite.OpenWeb(SPContext.Current.Web.ID))
{
// Perform elevated actions here
}
}
instead of using old
SPSecurity.RunWithElevatedPrivilege(delegate()
{
using(var systemSite = new SPSite(SPContext.Current.Web.Url))
{
using (var sysWeb = systemSite.OpenWeb(SPContext.Current.Web.ID))
{
// Perform elevated actions here
}
}
});
That is and the production issues gone. So from now I would add one more entry to the list, Minimalize using RunWithElevatedPrivilege in your code, and use SPUserToken instead.
-o0o-
Indonesia (see English version)
Bagi rekan-rekan yang sering bekerja dengan SharePoint Designer, pesan kesalahan berikut ini pasti sering dijumpai “Error page has been modified”. Penyebabnya jelas sekali, karena kita membuka halaman di browser sementara di balik layar dilakukan editing dengan menggunakan SharePoint Designer. Kemudian setelah melakukan editing dan menyimpan halaman di SharePoint designer, kita langsung mengklik salah satu link di halaman yang telah dibuka. Cara mengatasinya cukup mudah , kembali ke halaman semula , refresh dan link-link akan bisa diakses seperti semula.

Tetapi bagaimana dengan kejadian yang muncul di server produksi? Di server produksi, tidak seorang pun mengedit halaman dengan SharePoint Designer. Jadi apa yang bisa menyebabkan “Error page has been modified” ?
Seperti biasa, saya mencari-cari informasi di internet dan menemukan beberapa hal dibawah yang mungkin dapat membantu:
1. Ada fitur yang ada di datastore tapi hilang secara fisik (http://forums.technet.microsoft.com/en-US/sharepointgeneral/thread/9a98188b-9dec-4d85-b8b7-47ba41e5271f/)
2. Tidak menggunakan TemplateRedirectionPage tapi PublishingLayoutsPage (http://blogs.msdn.com/tejasr/archive/2008/06/19/resolution-moss-this-page-has-been-modified-since-you-opened-it-you-must-open-the-page-again.aspx)
3. Menggunakan NLB dengan affinity diatur none (http://support.microsoft.com/kb/892348)
4. Beberapa mengatakan bahwa perbaikan prosedur keamanan di MOSS SP1 (KB936984) /WSS SP1 (KB936988) akan membantu menyelesaikan masalah.
Sayangnya semua hal diatas sudah terpenuhi, tetapi tetap saja masalah tersebut muncul. Sampai akhirnya saya membaca artikel tentang RunWithElevatedPrivilege - “The evil’s of RunWithElevatedPrivilege dari Danniel Larson”. Dari penjelasan yang ada, saya menduga bahwa penyebabnya adalah karena prosedur tersebut mengganti identitas thread dan menjalankan di thread lain, sehingga halaman yang sedang dibuka akan kehilangan “hubungan” dengan server (mirip dengan pada saat kita menyimpan dengan menggunakan SharePoint Designer). Akibatnya, link-link yang ada di halaman sudah tidak valid lagi dan muncul “Error page has been modified”.
Berbekal dari dugaan itu, saya kemudian meminta rekan-rekan di team untuk mengganti cara impersonation untuk mengugnakan SPUserToken
SPUserToken sysToken = SPContext.Current.Site.SystemAccount.UserToken;
using(var systemSite = new SPSite(SPContext.Current.Site.ID, sysToken))
{
using (var sysWeb = systemSite.OpenWeb(SPContext.Current.Web.ID))
{
// Perform elevated actions here
}
}
dan menghapus RunWithElevatedPrivilege
SPSecurity.RunWithElevatedPrivilege(delegate()
{
using(var systemSite = new SPSite(SPContext.Current.Web.Url))
{
using (var sysWeb = systemSite.OpenWeb(SPContext.Current.Web.ID))
{
// Perform elevated actions here
}
}
});
Dan seperti yang diharapkan, masalah di production akhirnya teratasi. Jadi mulai dari saat ini saya akan menambahkan satu lagi di dalam daftar , Kurangi penggunaan RunWithElevatedPrivilege dan sedapat mungkin gunakan SPUserToken.
English (versi bahasa Indonesia)
Weather webpart is one of most popular wepart to place in homepage. Many available resources out-there in internet using C# and webservices. But instead of create weather webpart using Visual Studio I will show you how create it using SharePoint Designer.

The process is pretty simple,
1. You need to create a new page in Sharepoint as working canvas.
2. In that working canvas, drop webpart zone and dataview webpart.
3. Find appropriate weather datasource and format dataview webpart.
4. Export the new formatted webpart and delete working canvas.
5. Distribute / use the webpart. Package in solution file if necessary.
Initially open SharePoint site using SharePoint Designer. To prepare a page for working canvas, just create a new aspx page.

On the new page, attach default master page by using attach master page under format menu.

On the PlaceHolderMain in the page, click Create Custom Content to detach this section from master page.

Then in the new custom content area, insert “Web Part Zone” and “Data View” component from SharePoint Controls.

Next, we need the reference to get weather information from. SharePoint designer provides wide range of data source type, starting from SharePoint List, SharePoint Libraries, Database Connection, XML Files, Server-side scripts, XML Web Services and Linked sources. Since my country has “BMG” which announce weather data officially, in this case I will use XML files as my datasource.

For me, the location of weather data is http://www.bmg.go.id/dataxml/cuaca_indo_1.xml or http://www.bmg.go.id/dataxml/cuaca_indo_2.xml. Saving that location into XML data files, give me a new datasource to working with.

Then click Show Data on the new datasource.

In the data source detail, we can select appropriate fields to show. In this case I select “Kota”, “Cuaca”, “SuhuMin” and “SuhuMax”. And then click Multiple Item View.

By default you will get a table from XML datasource. Like the one bellow.

Since I only want few big cities in Indonesia, then I click filter on the Common Data View Tasks.

Next, is to insert icons to describe weather conditions such as raining, clear, clouds etc. To select appropriate icon, we can test on the “Cuaca” field and choose correct icon ( inspect line number 108 – 118 in the figure below). I also make the table into single column by moving the field content into leftmost column and deleting other column in original table.

Since I transform to single column, then I don’t need to keep the header anymore. So I just change the header into long cell title.

Saving the page and opening in browser, allows me to export the webpart and import back in the future.

Thats for now, just couple minutes to create weather webpart. For you who curious with the webpart, please download it from the attachment ( BMGLike.webpart (17 KB) ).
-o0o-
Indonesia (see English version)
Webpart cuaca merupakan salah satu webpart populer yang sering diminta oleh client. Di internet bisa kita temukan webpart cuaca yang berbayar maupun gratis yang dibuat dengan C# dan web services. Di artikel ini, alih-alih membuat webpart dengan menggunakan Visual Studio, saya akan mendemonstrasikan pembuatannya dengan menggunakan SharePoint Designer.

Prosedurnya cukup sederhana,
1. Buat halaman aspx di SharePoint sebagai tempat eksperimen.
2. Tambahkan webpart zone dan dataview webpart di halaman kerja tersebut.
3. Tambahkan sumber data cuaca yang sesuai dan format dataview webpart agar tampil cantik.
4. Export webpart yang baru ke dalam 1 file dan hapus halaman kerja.
5. Distribusikan webpart dan masukkan ke dalam solution package jika perlu.
Untuk menyiapkan halaman kerja, buka SharePoint site dengan menggunakan SharePoint Designer. Dari menu file, buat sebuah halaman ASPX baru.

Di dalama yang baru terbentuk, buat referensi ke master page dengan menggunakan menu attach master page.

Setelah di-tempel dengan master page, maka secara default design dan isi halaman akan mengikuti master page. Klik Create Custom Content di bagian PlaceHolderMain untuk memulai membuat kustomisasi di halaman itu.

Di area custom content yang baru terbentuk, tambahkan “Web Part Zone” dan “Data View” webpart didalamnya.

Selanjutnya yang kita butuhkan adalah sumber data. SharePoint Designer memberikan kemudahan untuk menggunakan beberapa jenis sumber data misalnya, SharePoint List, SharePoint Libraries, Database Connection, XML Files, Server-side scripts, XML Web Services dan Linked sources. Disini saya akan menggunakan data yang disediakan secara cuma-cuma oleh BMG , berupa XML file. Kita dapat langsung menggunakan referensi berupa URL ke XML yang bersangkutan.

Lokasi XML data yang disediakan oleh BMG adalah di http://www.bmg.go.id/dataxml/cuaca_indo_1.xml atau http://www.bmg.go.id/dataxml/cuaca_indo_2.xml. Simpan informasi lokasi tersebut sebagai sumber data XML yang baru.

Kemudian klik “Show Data” pada sumber data XML yang terbentuk.

Didalam data source detail, kita dapat menentukan field-field yang akan ditampilkan. Disini kita ambil “Kota”, “Cuaca”, “SuhuMin” dan “SuhuMax”. Kemudian klik Multiple Item View.

Secara otomatis, kita akan memperoleh tabel yang diperoleh dari field-field yang ditentukan tadi, seperti dibawah.

Kita juga dapat memfilter agar menampilkan beberapa kota besar di Indonesia saja. Caranya, dengan menentukan filter dari properti data view webpart di Common Data View Tasks.

Agar tampilannya menjadi cantik, kita bisa menambahkan icon untuk hujan, cerah, berawan dsb. Untuk mendapatkan icon yang sesuai, maka kita gunakan xsl:choose dan mengetes nilai field Cuaca (perhatikan baris 108 – 118 pada gambar dibawah). Saya juga mengubah tabel menjadi 1 kolom, dengan memindahkan isi field lain ke kolom paling kiri dan menghapus kolom yang tidak digunakan.

Judul tabel juga diubah dengan mengubah table headernya, dan menyesuaikan dengan format 1 kolom.

Simpan halaman yang sudah selesai diedit dan kemudian buka di browser. Hasilnya adalah halaman dengan weather webpart yang baru, tugas kita berikutnya adalah mengeksport webpart tersebut dan siap untuk didistribusikan.

Akhirnya, mudah-mudahan step-by-step diatas memberikan ide untuk rekan-rekan semua. Untuk yang tidak mau report, berikut ini adalah webpart yang sudah jadi ( BMGLike.webpart (17 KB) )