.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Easy Web
Imran Ghani

Home >> Interview Question >> SharePoint >> Post New Question Subscribe to Interview Questions

In Sandbox solution use RunWithElevatedPriviledges? why?

Posted By :Sagar Pardeshi     Posted Date :February 21, 2011    Points :15   Category :SharePoint 
we can't elevate privileges in such an environment and we land up with complex solutions, Sandboxes are used when executable code comes from unknown or untrusted sources and allow the user to run untrusted code safely.RunWithElevatedPrivileges which runs the specified block of code in application pool account(typically System Account) context is not allowed in Sandbox code. SPSecurity class also not allowed to use in Sandbox.


You can also find related Interview Question to In Sandbox solution use RunWithElevatedPriviledges? why?  below: 

Difference between sandbox solution and farm solution

  
SharePoint 2010 introduces new feature sandbox solution.Here are major difference between sandbox solution and farm solution.

1.The scope of sandbox solution is site collection where as The scope of farm level solution is farm level.

2.Sandboxed solutions, which are hosted in the SharePoint user code solution worker process (SPUCWorkerProcess.exe)Whereas Sandboxed solutions, which are hosted in the SharePoint user code solution worker process (SPUCWorkerProcess.exe)

3.Sandbox run code that can only affect the site collection of the solution.The process runs under a CAS policy that restricts programmatic access to any resource outside the sandbox.Whereas Farm Solution run code that can affect the whole farm.

4.Sandbox Never restart the IIS application pool.If you run any code it will affect only the site collection of the solution. Whereas If you deploy any feature or retract any feature the whole application pool got recycled in farm solution.

5.Sandboxed solutions are uploaded and activated whereas Farm solutions are installed and deployed.

6.we can’t create VISUAL web parts in Sandbox solutions whereas VISUAL web parts can be created in farm solution.

7.When the Sandboxed Solution property is set to True, selecting Build\Deploy Solution deploys the solution to the site collection Solution Gallery.whereas When the Sandboxed Solution property is set to False, selecting Build\Deploy will deploy the solution to the Farm Solution Gallery. (More...)

How many processes implemented sandbox solution?

  
There are three processes
1.SPUCHostservice.exe
2.SPUCWorkerprocess.exe
3.SPUCWorkerProcessProxy.exe (More...)

Can I easily rename a solution or project?

  
Yes-right-click from the Solution Explorer and choose Rename.You'll also have to edit the namespace declarations in any source code files you've created. (More...)

Real software is developing a speech-based user interface for blind people. However, speech based interface are difficult to design and time given by the client is short. To develop a functional interface without any errors, the company wants to first evaluate the prototype. They used the storyboard technique to demonstrate the functionality of the application. However, this technique was unable to demonstrate the interactive feature of the application. Analyze and provide solution for the above scenario?

  
1, The design team of Real software should have used the Sketching technique because storyboard technique would only provide the flow and features of the interface.

2, The design team of Real software should have used the Horizontal Prototyping because storyboard technique would only provide the flow of the interface.

3, The design team of Real software should have used the Wizard of Oz technique because storyboard technique would only provide the flow and features of the interface

4, The design team of Real software should have used the Vertical Prototyping because storyboard technique would only provide the flow of the interface.


Answer : 3 (More...)

What is a SharePoint Solution File? How does it differ from WebPart .cab files in legacy development? What does it contain?

  
A SharePoint solution file is essentially a .cabinet file with all a developers ustom componets suffixed with a .wsp extension that aids in deployment. The big difference with SharePoint solution files is is that a solution:
allows deployment to all WFE's in a farm
is highly manageable from the interface allowing deployment, retraction, and versioning
Can package all types of assets like site definitions, feature definitions (and associated components), Webparts, etc.
Can provide Code Access Security provisioning to avoid GAC deployments
And much more..
(More...)

What is a .ddf file and what does it have to do with SharePoint Solution creation?

  
A .ddf file is a data directive file and is used when building the SharePoint solution bundle specifying the source files and their destination locations. The important thing for someone to understand is that the .ddf file will be passed as a parameter to the MAKECAB utility to orchestrate construction of the SharePoint solution file.
(More...)

What is a SharePoint Solution File? How does it differ from WebPart .cab files in legacy development? What does it contain?

  
A SharePoint solution file is essentially a .cabinet file with all a developers ustom componets suffixed with a .wsp extension that aids in deployment. The big difference with SharePoint solution files is is that a solution: allows deployment to all WFE's in a farm is highly manageable from the interface allowing deployment, retraction, and versioning Can package all types of assets like site definitions, feature definitions (and associated components), Webparts, etc. Can provide Code Access Security provisioning to avoid GAC deployments Just to name a few things. (More...)

Describe the difference between inline and code behind - which is best in a loosely coupled solution

  
ASP.NET supports two modes of page development: Page logic code that is written inside runat="server"> blocks within an .aspx file and dynamically compiled the first time the page is requested on the server. Page logic code that is written within an external class that is compiled prior to deployment on a server and linked ""behind"" the .aspx file at run time. (More...)

how deploy sharepoint solution(WSP)using STSADM Utility?

  
stsadm.exe -o retractsolution -name yourtemplate.wsp -immediate
2. stsadm.exe -o execadmsvcjobs
3. stsadm.exe -o addsolution -filename yourtemplate.wsp
4. stsadm.exe -o deploysolution -name yourtemplate.wsp -allowgacdeployment -immediate -force
5. stsadm.exe -o execadmsvcjobs
(More...)

What could be the solution of one click deployment in windows forms?

  
ClickOnce deployment tool is the solution of one click deployment in windows forms Application (More...)

What is a sandboxed solution?

  

Components that are deployed to run within the sandboxed process rather than running in the production Internet Information Services (IIS) worker process. (More...)

. How will you cancel a deployment from central admin -> solution managment, if its stuck at "deploying" or "Error".

  
Ans. You can either try to force execute timer jobs using execadmsvcjobs command or can cancel the dpeloyment using stsadm command stsadm -o cancaldeployment -id {GUID} command. The Id here would be GUID of the timer or deployment job. You can get the Id from stsadm enumdeployment command. This will display all the deployments which are process or are stuck with Error. (More...)

Quick Links For Interview Questions Categories:
ASP.Net Windows Application   .NET Framework   C#   VB.Net   ADO.Net  
Sql Server   SharePoint   Silverlight   OOPs   JQuery   JavaScript/VBScript
Biztalk Patten/Practices .IIS WCF WPF WWF
Networking Aptitude Others   All      

Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.

 
Now you can find lots of .NET, C#, Vb.Net, SQL Server,Windows, ASP.Net related Questions and their Answers here at www.dotnetspark.com. Our aim is to help you pass your certification Exams (MCP, MCSD, MCAD etc.,) with flying scores and get good name in your company.

So, Start looking our Interview Question section daily and improve your .NET Skills. You can also help others by posting Interview Questions and their Answers in this section.


Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend