Making a sharepoint site (2007) read only - sharepoint-2007

I am getting ready to perform a migration of SharePoint 2007 to 2010, and during the migration horus, i will want to prevent anyone form adding content anywhere, but yet I would like for people to read the content. Is there a way to make the sharepoint 2007 site read only?

Try:
stsadm -o setsitelock -url http://server_name -lock noaccess
That will help you set the site collection to read-only

Its very simple:
Central Administration > Application Management > Site Collection Quotas and Locks. Then choose 'Read Only'.

If you are performing a database attach upgrade, you could set the databases to read-only through SQL Management Studio. When SharePoint databases are set to read-only, SharePoint will automatically security-trim all sites in those databases to only allow for viewing the content.

I'm not sure if there is a way to do it in the UI or through stsadm, but there is a readonly property of the SPSiteAdministration object.
SPSiteAdministration siteAdmin = new SPSiteAdministration(siteUrl/guid);
siteAdmin.ReadOnly = true;
siteAdmin.Dispose();

Related

Customize the TFS web dashboard

Like the title says, how can I customize the web dashboard in TFS 2012? I have created my own Work Item Type and would like a shortcut on the home page of Team Web Access. I am using the default Team Web Access page and I would just like to have a shortcut button immediately on the front page instead of in a dropdown, which is where it's contained now.
Thanks!
There is no supported way to do this. In TFS 2015 they have the concept of Web Extensions, but that is only for specific extension points which doesn't include changing the home page.
You can do it in an unsupported manner, but I wouldn't recommend it. You can find the ASPX/CSS/JS files on the server that TFS uses for the web site and hack away at them. I've known people that have done this before. But there are probably repercussions when it comes time to upgrade.
For posterity, I've found a dirty solution to do this without cloning the website and gutting it (as described here: http://awaitwisdom.com/how-to-extend-tfs-team-web-access/). Note that this solution is really dirty and may not fit your project needs.
The solution works by swapping the default work item options (based on the process template you are using).
Use WITADMIN to export your Categories into an XML. Find a work item currently on the front page that you're okay with swapping out for the work item you want to be on the front page. Change "DEFAULTWORKITEMTYPE" to "WORKITEMTYPE" in the tags. Add a new entry: and it should show up as one of the shortcut buttons on your home page.
I highly recommend doing your modifications with Microsoft TFS Power Tools 2012.

Sharepoint 2007 core.css

Sharepoint 2007:
Core.css file is located in the 12 Folder:
12\TEMPLATE\LAYOUTS\1033\STYLES
but my question is : is this file shared for all webapplications on sharepoint server?
I think it is not because when I make changes in the core.css, only one of the applications showed the changes, so where is the others core.css files located?
I made search in my c driver I find only one core.css!!!!
Thanks in advance
This file is shared by all Web Applications. What you experience is most likely a result of aggressive client side web browser caching. Try clearing your browsers cache and refresh the page.
Having said that...
This is not the way you are supposed to customize SharePoint. You should never touch the OOB files in the 12 hive. Next time you apply an update or service pack all of your changes are gone. Also, by touching the OOB files, you automatically lose all support from Microsoft.
Rather, you should either a) develop a SharePoint feature that publish a custom master page with your CSS changes or b) do master page changes using SharePoint designer.
Core.css is always shared by all web applications.
AS magnus said what u have seen is due to the browser caching or somehthing like that. delete the browser cache or Restart the browser and then try again..
May this help you
Thanks

Reading pst (Outlook) files from IIS ASP.NET application

I have to create sort of a .PST file based Web Mail.
I need to read all MailItems, Folders, Contacts and everything i can from PST files given by the user.
I am currently using DCOM interop to create a Application and use Session to add my file's stores.
My problem is that i can't even instantiate the Outlook.Application, the code simply doesn't run.
If i change to Visual Studio Development Web Server everything works as perfectly as expected, but if i change to local IIS Web Server.. nothing happens =/
What i did so far:
Set username and pass to impersonate on web.config
Set username and pass to inpersonate on my WebSite from iis -> Authentication -> ASP.NET impersonation
Added permissions to Everyone, Network Service, IIS_IUSRS, my user account in temp asp files, web site file and pst files i'm trying to read
Unfortunately I've already implemented all I need using TDD, so it would not be a good idea to change the way i'm doing this, like moving to NMapi or something.
Thanks in advance
EDIT:
As i've mentioned before, i I cannot use another library (and that one seems to work, but it's pretty expensive).
I only need this to run on a local server. It is a Web application, but for localhost ONLY.
It is not a good idea to use Outlook on the server side, as is described in detail here: http://support.microsoft.com/kb/257757
Microsoft does not currently recommend, and does not support,
Automation of Microsoft Office applications from any unattended,
non-interactive client application or component (including ASP,
ASP.NET, DCOM, and NT Services), because Office may exhibit unstable
behavior and/or deadlock when Office is run in this environment.
Maybe have a look at http://www.independentsoft.de/pst/

TFS 2005: Sharepoint site not working

I've just created a new Test instance of TFS 2005 SP1 and migrated the databases. The TFS part seems to work correctly, but the Sharepoint site doesn't seem to work.
http://TfsServer/sites/Project1/default.aspx gives a 404 error.
Also heading to Sharepoint Central Administration --> Manage Site collection owners and entering the above site name under 'Web Site URL' gives the following error message:
'The virtual server that is referenced here is not in the config database"
The config database is the only one I did not restore from the source (following instructions here). How do I go about recreating the Sharepoint site?
Thanks!
Sharepoint Central Admin
Manage Web Server List
click on server name
Configure Virtual Server settings
Default Web site
Manage Content Databases
Click on STS_Content_TFS
Note the values in textboxes.
Check Remove content database and click on OK.
Recreate content database with the same name (STS_Content_TFS) and other information
as above.

How do I access the ASP.NET Configuration Tool when a site is live? This is ASP.NET MVC

I was wondering if it's possible to access the ASP.NET Configuration Tool once a site is live. To be able to create and edit users and roles is obviously very important, and from what I've been reading, once a site is deployed, the Configuration Tool is no longer accessible. If this is the case, HOW do I add users, etc.?
By the way, I found a User Management plugin which brings a lot of the Configuration Tool's capabilities to the front end of a User Management section of the deployed website, but it DOES NOT offer the capability to add a new user. Help??? Thanks!!
That all depends. If by "going live" you mean "Publishing the website and the database to a different computer through which you cannot access the database any longer", then yes. If you still have sql access (ie. you can run SQL Management Studio from your dev machien) the no you can access it by changing your web.config.
Alternatively, you can install Visual Studio express on your remote server and be able to access it from there.
The ASP.NET Configuration Tool GUI is not available once the site is live unless you have access to the database from your development machine.
All of the settings for user authentication can be modified via your web.config file.
You can add/edit users and roles via the Membership and Roles class in the System.Web.Security namespace.
1: Website admin tool is accessible via Visual Studio only.
2: You can access your membership database on live via WSAT by changing connectionstring in your web.config to point to your live membership db.
Apart from using WSAT, asp.net has CreateUser control which you can use to create user on live. This is the same control used by WSAT.
These links should help:
CreateUserWizard
Custom WSAT Tool
http://weblogs.asp.net/scottgu/archive/2005/10/18/427754.aspx

Resources