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


Top 5 Contributors of the Month
david stephan
Asad Ali
Post New Web Links

Put value by default in a SharePoint:FormField

Posted By:      Posted Date: September 15, 2010    Points: 0   Category :SharePoint
 
Hi all I would like to put a value by default in one text field. That value musct catch from a value called @ID (it comes from  the query string). I wanted to put in the Value attribute from the SharePoint:FormField tag, but it says: it can assign @ID to Value since Value is a object.Is the value property the correct one to put my value by default? If so, how can get this one?                    <td class="ms-vb">                         <SharePoint:FormField runat="server" id="ff4{$Pos}" ControlMode="Edit" FieldName="Task_x0020_Id"  __designer:bind="{ddwrt:DataBind('u',concat('ff4',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Task_x0020_Id')}" />                         <SharePoint:FieldDescription runat="server" id="ff4description{$Pos}" FieldName="Task_x0020_Id" ControlMode="Edit" /></td>  Kind Regards!


View Complete Post


More Related Resource Links

IIS - sharepoint/default website port number confusion

  

Hi,

I have MOSS 2007 installed with IIS V7.

My default web site port is 80. When I created a new web application for my main sharepoint portal I also set it to 80. So obviously now the default web site port shows as stopped in IIS and it won't start.

What are the best practices. Should I change the port number for my portal to something else? I mean is it even a good idea to have sharepoint on port 80? If so, how do I go about changing the port number for my portal site?

any help appreciated.


Problem Saving Files to A Sharepoint 2010 Site from Office 2010: Saves locally by default rather tha

  
Hi we are starting to use sharepoint 2010 / word 2010 and have found an interesting bug/problem. Sometimes when a user tries to save a file (by clicking on the save button in the quick access toolbar for word 2010) the save dialog comes up with the users local "Documents" folder as the path (not the correct sharepoint path where the document should be saved).  (I should say that we are creating the file from sharepoint by using a toolbar on the document library, with the new button)  We are using a content type and a template attached to the document library when we create the file.  This is really annoying because the user might not notice that the document is saving locally and not to sharepoint.  I have found a strange workaround which involves clicking the [File] tab on the ribbon in word 2010, then clicking "Save and Send" and then clicking the save button again.  At this point word 2010 seems to "remember" that it is trying to save document to sharepoint and shows the sharepoint document library. This is a real nuisance which could lead to documents being lost/misfiled if people don't realize that this is happening.  Can anyone help me? Thanks Kevin krd

modify/override properties of default sharepoint modal dialogs (ex. editview.aspx) using javascript

  
Hello all, I would like to know how can I modify (override) some properties of the default sharepoint modal dialogs using Javascript. Ex. the size and location of editview.aspx. I while ago I asked a question about overriding the DialogResult in the display view dialog. I got an answer from Zach which looked like this:             sb.Append("<script type=\"text/javascript\">");             sb.Append(@"window.setTimeout(function () {");             sb.Append(@"if (window.frameElement && typeof(window.frameElement.overrideDialogResult) == 'function')");             sb.Append(@"{");             sb.Append(@"SP.SOD.executeFunc('sp.ui.dialog.js', 'SP.UI.DialogResult.OK', function () {");             sb.Append(@"window.frameElement.overrideDialogResult(SP.UI.DialogResult.OK); ");             sb.Append(@"});");             sb.Append(@"}");  

default value for MySite's 'As Seen By' web part in SharePoint 2010

  
Does anyone know how to change the default value for the 'As seen by' web part on the SharePoint 2010 MySite's person.aspx page? Currently it defaults to "Everyone' and our client would like it to default to 'Only Me'. Is this even possible? Regards, Kyle

Custom Default.aspx SharePoint 2010

  
I would like to replace the default.aspx with a custom default.aspx.  I have been able to accomplish this with a feature. I am finding the when deployed the new default.aspx page shows up in the following directory C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\FEATURES\ProjectInsightSPMaster_ProjectInsightLayoutFeature\defaultpage I also have a default.aspx located in the following directory.  This is the one that is deployed with the site definition. C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\SiteTemplates\PISP    When I browse to a site in IE, it is in fact looking at the correct (new) default.aspx page which is located in the FEATURES directory.  How does SharePoint know to use this default.aspx page instead of the one located in the SiteTemplates directory.  This is confusing to me.  Can you explain?   Is this the correct way of deploying an updated default.aspx?   dave

SharePoint - Defaulting a Value into the obscure SharePoint:FormField controlMode=New code line

  
I think I've done it before somehow. but can't remember. Is there any way to force a default value into this  Markup? I've tried a few things with no luck.  Iknow i can doing in javascript codek but wanted to double check I might just not be able to force it here. The code below is binding my a column textbox to a list column while in insert mode.  Generated when I ask the DataView Designer to create a NEW button.  I just want to force the value of a querystring parameter into the column and really not even see the column. Thanks     <SharePoint:FormField runat="server" id="ff3{$Pos}" ControlMode="New" FieldName="Title" __designer:bind="{ddwrt:DataBind('i',concat('ff3',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}" />

SharePoint how does it know to use a feature default.aspx deployed instead of site definition defaul

  
I have created a feature which deploys a custom default.aspx page. The deployed file goes to the template\features{featureName} directory. How does SharePoint know to use this default.aspx page instead of the one that is located in SiteTemplates{Site Def name} directory?dave

How do you modify default workflow (out-of-the-box) in sharepoint designer ?

  

How do you modify default workflow (out-of-the-box) in sharepoint designer .


Thanks and Regards Er.Pradipta Nayak

Using Filter in SharePoint FormField Lookup Column

  

I have a FormField lookup column with multiselect, which is bound to a List.

I have a new requirement.. There will be a textbox and a filter button above the FormField and when ever the user enter something and click on the filter button, the FormField lookup value should be filtered depending upon the string value in the textbox.

Please help me if somebody already done something like this or if someone has some idea how to do it..


Creating default SharePoint groups for upgraded sites

  

Hello,

I am doing some testing in preparation for a DB attach upgrade from MOSS 2007 to SharePoint Server 2010, and I've run across a bunch of old sites that do not have the default Owners, Members, and Visitors groups. Without those groups (specifically, without Members) we won't be able to take full advantage of the My Sites Memberships page. 

I noticed, though, that when I "Enable Enterprise Features" for all current sites from within Central Administration, sometimes those groups get created on a site that didn't have them before. I've done this on a few different environments and it doesn't seem to always create those groups. Now, I didn't think I had to run Enable Enterprise Features because our 2007 environment was Enterprise, but then I realized some of the sites were created back in SharePoint 2003 and enterprise features might never have been run on the sites when it was upgraded to MOSS 2007. 

So the question: is running Enable Enterprise Features for current sites supposed to create the default groups if they don't exist (along with everything else it does)? Is that the recommended way to get groups made for all sites so site admins/owners can add people to that new Members group which allows the users to visit their My Site page to view all the sites they are members of?

Thanks,
Aaron


Unable to pass default network credentials from a .NET / SharePoint application to Web Services

  

Require some help in passing the authentication of a logged-in user to a web services (which is a wsdl file added as web reference to the application) from an ASP.NET application/ SharePoint 2010 portal. When the application calls the web service, the default network credentials need to be passed to the web service to get authenticated to use the data repository. This web service is used for searching a data repository depending on the logged in user's credentials and search query.

We have made necessary changes required in the applications like.

Necessary changes in web.config (like authentication mode to Windows, impersonation is made true). Install client certificates to the trusted location.

Enable IE 8.0 to use Integrated Windows authentication (Internet Explorer -->Tools-->Internet Options -->Advanced--> Security --> Enable Integrated Windows Authentication.

Default domain logon on sharepoint

  

Hello!

I don't want anymore to type DOMAIN\username every time I want to connect in my sharepoint 2010 (W2k8 R2) from my home pc for example, how can I do this?

Thank you,
Yuri.


Sharepoint doesn't redirect to default.aspx

  

While logged in as a User in Sharepoint 2010, if I navigate to the main page of our Sharepoint (http://sharepoint) it asks for my username and password but never actually logs on (stuck in a loop). If I navigate straight to http://sharepoint/default.aspx, it works fine.

If I'm logged in as the System Account admin, then navigating to http://sharepoint redirects me automatically to /default.aspx.


Unable to pass default network credentials from a .NET / SharePoint application to Web Services

  

Require some help in passing the authentication of a logged-in user to a web services (which is a wsdl file added as web reference to the application) from an ASP.NET application/ SharePoint 2010 portal. When the application calls the web service, the default network credentials need to be passed to the web service to get authenticated to use the data repository. This web service is used for searching a data repository depending on the logged in user's credentials and search query.

We have made necessary changes required in the applications like.

Necessary changes in web.config (like authentication mode to Windows, impersonation is made true). Install client certificates to the trusted location.

Enable IE 8.0 to use Integrated Windows authentication (Internet Explorer -->Tools-->Internet Options -->Advanced--> Security --> Enable Integrated Windows Authentication.

Even the web services have methods to get the windows network credentials. While trying the following code, to pass current credentials, default credentials is empty.

myProxy.Credentials = System.Net.CredentialCache.DefaultCredentials (Here it is a null value)

Application is using Windows Authentication | NTLM.

The following code works, if the authenticat

Sharepoint does NOT redirect to default.aspx

  

 

Hi, my sharepoint installation seems to be broken

 

If I navigate to http://mysite/sites/site1 it does not redirect to http://mysite/sites/site1/default.aspx

 

It does not work for any site.  Any ideas on how to fix it? 


Sharepoint IIS Default WebSite ASP.NET impersonation

  

Curious why ASP.NET impersonation is enabled by default.  Is it because sharepoint needs this enabled?  I would like to disable so that I can use Windows Authentication for custom web parts to access a remote sql server, this way I can use the domain user i set for the app pool.  Or is there a recommended way?


Sharepoint IIS Default WebSite ASP.NET impersonation

  

Curious why ASP.NET impersonation is enabled by default.  Is it because sharepoint needs this enabled?  I would like to disable so that I can use Windows Authentication for custom web parts to access a remote sql server, this way I can use the domain user i set for the app pool.  Or is there a recommended way?


Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

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