I am adding moss contentdb to sharepoint 2010 web application using stsadm -addcontentdb command via c# code.after few minutes it successfully adding.but i need to show the percentage completion (Progress bar) at the time adding contentdb.How can I get t开发者_如何学Gohe percentage value.
I don't think sharepoint exposes such counters for these operations. As an alternative, what you can do is, if this is a web application, you can display standard sharepoint progess indicator using sharepoint API:
http://blogs.msdn.com/b/sumanc/archive/2009/01/25/how-do-i-create-a-long-running-operation-page-gears-page.aspx
精彩评论