Latest developer linksBookmark and Share
 
HomeThis WeekTop MonthTop AlltimeSearchRegisterFAQ
  
 
Submit Your Link
Please login to submit your Link
 

Add user permisison after submitting to form library

Posted: Jan/18/2011   By: nikhil   Points:15   Category: .NET  - ASP.Net    Views:12   Vote Up (0)   Vote Down (0)    
I have an InfoPath 2007 MOSS form that is a default content type for a document library. When the user submits the form a SPD custom workflow is fired that starts a multi-step approval process. Users have the ability to submit this form on another user's behalf (i.e. secretary submits for her boss). However, the form library permissions only allow users to see their own submissions.

The issue I am having relates to when a secretary submits a form for her boss, the boss cannot view the form or workflow progress. I have experimented with adding "grant permisison on item" step in workflow with no success. The workflow just kind of dies when I add that step in. What is the best way to give permisison to the item for the user it was submitted on behalf of once it is submitted?

View Complete Post


Comments:
Be the first to comment this post.
 
Post Comment
Please login to post your comment
More Related Resources

Loading User Controls Dynamically

  
User Controls are great in ASP.NET. They let us divide the page into small sections. You can easily use User Controls on a ASP.NET page by simply dragging and dropping the control from the solution explorer. Sometimes we need to load the User Control dynamically. In this small article we will learn how to load the User Control dynamically.

php user migrating to asp.net

  

Hi, I have a website that I need to add some dynamic data from asp.net, I'm completely new to .net and am having some problems (usually a php user).

K so, I have
a simple html tag
<a href="" title = "" >my link</a>

Now all I want to do is to insert some data in to the href and title parameters. in php I would just use <a href="<?php echo myHrefvar?>" title = "<?php echo myTitlevar?>" >my link</a>

I've tried doing
<a href="<% = myHrefvar%>" title = "<% = myTitlevar%>" >my link</a>

and in my default.aspx.cs I have the variables being set
string myHrefvar = "my href";
string myTitlevar = "my title";

but it always gives the message that they're not linked.

Have also tried
<a href="" title = "" ID=Req1>my link</a>

and in the apsx.cs file
Req1.HRef = "sdsdsd";
Req1.Title = "sdsdsd";

but again I get an error saying Req1 doesn't exist in the current context.

So help, I'm missing something rather fundamental here, any help would be much appreciated.

James


send alert message to user if close internet browser before save web form data

  

 Hi, I have window form to let user fill data, I want to alert user if close web browser before saved web form data, could anyone provide any clue?

 

Thanks,

Martin


How get clientID of a control in a ModalPopup of a User Control??

  

Hi,

I have a user control which has a modal popup. This modal popup has a grid and few controls like textboxes and comboboxes. I am trying to clear out all the controls when the close button is clicked. I am using javascript to close the modalpopup. but to clear the controls, $get('<%=txtbox1.clientID%>') method is returning null. can someone please help me?


Here is my code snippet.

function close_Click() {
    var mdlPopup1;
    mdlPopup1 = $find('modalPopup');
    mdlPopup1.add_hidden(clearInputFields);
    mdlPopup1.hide();
    
}

    function clearInputFields() {
        var name = $get('<%=txtName.clientID%>');

        name.value="";
       }


User control does not let me assign values into Text boxes

  

Hello,

Got a problem that I do not know what is going on (using c# and .NET 2008):

I have a main web page and added a user control inside it. The user control has some textboxes. The problem I have is when I populate the textboxes with the data that is in the DB, they do not show the values. The strange thing is If I change the property of textboxes ReadOnly to TRUE, they show the values. The problem is that I need them to be ReadOnly=FALSE.

Could anyone do help me please?

Thanks,

Marco


access to web form from class

  

hey,

i've read several posts with similar but problems, but i can't find one exactly like what i am seeing.  This is probably very simple...i just can't get the exact solution.

Platform is c#, VS 2010.

I have a web form and code behind file, with scripting that works just fine.  i'm trying to move script from the code behind file into a class, to consolodate and create re-use. The basic problem is when i move the script into the class, i cannot access the webform.

error here on "this":   HyperLink hyplAlertbox = (HyperLink)this.frmEtsuHome.FindControl(codeboxID);

i know WHY it throws the error, i just don't know how to fix it.  any help is appreciated.

below is simplified code....

------------------------------------------------------------------------------------------------

New Script in Code Behind File:


namespace myhome
{
    public partial class _default : System.Web.UI.Page
    {
                    
        protected void Page_Load(object sender, EventArgs e)
        {
             new majorAlerts();
             majorAlerts.GetAlerts();
             majorAlerts.ProcessAlerts(); } } }

-------------------------------------------------------------------------------------

Code for the Class

-------------------------------------------------------------------------------------


using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI.WebControls;
using System.Web.SessionState;
using System.Web.UI;
using System.Web.UI.WebControls.WebParts;

namespace myhome
{
    public class majorAlerts
    {
        
        public static void GetAlerts()
        {
            // grab the alerts and store them in a list                     
        }

public static void ParseAlerts(List<Alert> lAlerts) {
            foreach (Alert Alert in lAlerts) { // create codebox ID codeboxID = "codebox" + index.ToString(); // find hyperlink with ID of codeboxN cand reate an instance of it HyperLink hyplAlertbox = (HyperLink)this.frmMyHome.FindControl(codeboxID);

//******************* ERROR *************************************************
// ERROR ON this in previous line.  i understand, because "this" is not the form like it is in the code behind file.
// but i don't know how to modify "this" and make it work from class file
// **************************************************************************

 // set hyperlink URL value for alert based on alert ID alertURL = "http://www.blah.com"; hyplAlertbox.NavigateUrl = alertURL; } }




"Tabbed" Form with strongly typed model and validation after each tab

  

I got a very long user creation form with tons of validation.  Works fine.

Now I want to "split" this form into 5, displaying each form in a set of tabs (will be using jQuery UI Tabs).

So when you start, Tab1 is enabled, the rest not.

You finish what is in Tab1, and click "Next", the part of the original long form get validated (like a normal form using client side and remote validation .....it *must* be client side.  User Requirement.)

If valid, Tab2 becomes enabled, and also the user are shown Tab2.

Once the user get to finish and reach the last tab (which will basically just have a "Submit" button) I need to post everything that was entered across the series of tabs to the server (back to the single form/model/controller the existing form works on).

Any tips / advice / samples out there will be welcome.  (However not suggestions to change the requirements....picky as hell client)

Thanks for reading....


Failed to generate a user instance of SQL Server

  

 I am creating asp.net forms authentication. When I run web site and there I try to create new user I get this error:

Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

SQLExpress database file auto-creation error:

The connection string specifies a local Sql Server Express instance using a database location within the applications App_Data directory. The provider attempted to automatically create the application services database because the provider determined that the database does not exist. The following configuration requirements are necessary to successfully check for existence of the application services database and automatically create the application services database:

  1. If the applications App_Data directory does not already exist, the web server account must have read and write access to the applications directory. This is necessary because the web server account will automatically create the App_Data directory if it does not already exist.
  2. If the applications App_Data directory already exists, the web server account only requires read and write access to the applications App_Data directory. This is necessary because the web server account will attempt to verify that the Sql Server Express database already exists within the applications App_Data directory. Revoking read access on the App_Data directory from the web server account will prevent the provider from correctly determining if the Sql Server Express database already exists. This will cause an error when the provider attempts to create a duplicate of an already existing database. Write access is required because the web server accounts credentials are used when creating the new database.
  3. Sql Server Express must be installed on the machine.
  4. The process identity for the web server account must have a local user profile. See the readme document for details on how to create a local user profile for both machine and domain accounts.


Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace:

[SqlException (0x80131904): Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.]
   System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +4846887
   System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +194
   System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +2392
   System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK) +35
   System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject) +144
   System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +342
   System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +221
   System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +189
   System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +4861315
   System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup) +29
   System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +4863644
   System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +117
   System.Data.SqlClient.SqlConnection.Open() +122
   System.Web.Manage 

User name/Password unauthorized

  

 I'm trying to publish a site and I am fairly confident I have the publishing settings correct in WebMatrix Beta3.

Using the field instructions for WebMatrix provided by cytanium, I'm still not able to publish. The error I get when trying to validate the connection is:

 

Warning: User name/Password unauthorized. Again, I'm using the username and password provided.

 

Many thanks in advance for shedding some light on this.


how to work with the user who loggedin

  

hello every one,

i'm working in my first integral website ,and i'm using the ASP.NET Login Controls but now i need to know how i can work with the user who loggedin ,i wanna visable his Data only not the all users data ,like for example the site is contain medical data for every user  and when one user is logged in it will implement query to visual his Examination only.

Hope i present my Question well

 


 
Categories:
.NET
Java
PHP
C/C++/VC++
HTML/XML
SAP
MainFrames
Data Warehousing
Testing
MySQL
SQL Server
Oracle
Javascript/VB Script
Others
Login
 
 
 
 
 Forgot password
 Contact Us   Terms Of use   Share your knowledge