已答复 Threading in sharepoint?

  • 2012年7月31日 9:26
     
     

    hi,

    recently i created a webpart for submitting item in sharepoint list.

    two persons click submit button at the same time , one got an error that click back to browser and referesh the page.

    then i apply threading , could anybody tell me that in which scenerios one should apply threading.

    thanks,

    gaurav

全部回复

  • 2012年7月31日 20:03
     
     已答复
    when you two users access a web part page, ASP.net creates two seperate sessions for them. it means they are running their stuff in their own thread. ASP.net processes runs in seperate threads per requests etc. You do not need to implement seperate threading in a web part. Seperate threading would be required when you write some timer job type code, when there is only one instance running to perform a job and you want to process multiple things into seperate threads. It is not applicable to web parts. I hope you get the idea.

    Moonis Tahir MVP SharePoint,MCTS SharePoint 2010/2007, MCPD.net, MCSD.net, MCTS BizTalk 2006,SQL 2005

    • 已标记为答案 Jassik112 2012年7月31日 21:01
    •