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

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

passing form data between pages

Posted By:      Posted Date: October 08, 2010    Points: 0   Category :ASP.Net

Hi All,

I have to split a long form into two pages. In the first page, I have a  button "Next Page" to second page and in second page, a button "Previous page" to go to first page. How do I keep the form data when click "next page" and "previous page"?

I am using session variables to pass the form data. I have the server control Enableviewstat as true, but it still doesn't work. What else should I do? My code as below:

  protected void btnNext_Click(object sender, EventArgs e)
            Session["fname"]= txtFname.Text;



View Complete Post

More Related Resource Links

Passing data into a Sharepoint Designer Form Action workflow


I have a workflow that is triggered by a "Custom Action" on a "Form Action Button" that I added to a DataFormWebPart in SharePoint Designer. So the workflow isn't associated to any list or document library. What I need to do is pass some data to this workflow so that it can do some useful stuff.

I see from here that Natalya Voskresenskaya shows a method that allows you to pass a single list item value into a workflow variable but if you hack this into the aspx file as suggested, when ever you subsequently open design view and the workflow on the button again, all the hacks are removed by SPD.

I have tried this method and it seems to work for one variable, but I cant figure out how to pass more than one. Here is another post that is very similar but slightly different.

In this post Ibrahim said on April 1st 2008:

"I am having difficulty building a Javascript string for my particular requirement; SPD had already built a concat

Passing values in pages


Hi! Friends..

how to pass the value from one page to another page in asp.net  with out Using State Management Concepts?

Like 1. cookies


        3. QueryStrings

     With out using the above should pass the values...

Passing Data to a Cell in Excel



I have a webpage that is created in Visual Studio 2008 and programmed in C#.

I have a web form that prompts the user to enter a value into a text box.  For now, I do not have any validation on that field (I will be adding that later).

I need to pass the value that the user has entered to cell C1 of the excel spreadsheet (user_info.xls).

I understand that using excel is not ideal, but unforutnately need to try to make this work with the excel spreadsheet.

I do not have any code for this yet, because I honestly do not know how to begin.

The action of poulating the excel spreadsheet will be intialized from the On Click event of a Submit button.

Any suggestions would be much appreciated.

Thank you in advance for your assistance,


Form Filler: Build Workflows to Capture Data and Create Documents


Learn how to create a workflow that uses InfoPath forms and other office documents for passing data to targeted activities and for use in Office documents.

Rick Spiewak

MSDN Magazine June 2008

Using Server-Side XSL for Early Rendering: Generating Frequently Accessed Data-Driven Web Pages in A


Dynamic data-driven pages have become the basis of many cutting-edge Web sites. Early render systems can provide better performance and maintainability for data-driven Web sites by generating frequently accessed pages that contain less-volatile information ahead of time. We'll show you an example of a server-side solution that uses Extensible Stylesheet Language (XSL) to merge data and layout information into HTML that is compatible with just about any modern Web browser. Using these techniques to render Web pages early can reduce the load on your database back end and increase performance for your users.

Paul Enfield

MSDN Magazine April 2000

publicly publish some data from wiki pages


We have internal sharepoint site for the staffs which also has wiki pages. We want that wiki pages as public; publish some data from wiki pages.

To do this, one of my friend suggest me to do this:

"For exposing stuff publicly from SharePoint, you can do it using the SOAP interface from SharePoint and using .NET to make an app to read it. "

I'm just beginner of the sharepoint and I'm unable to follow his suggestion. This is not the easy step. 

Is anybody has some thoughts, ideas and some samples, if possible that would be great ?

I really appreciated. Thanks in advance.


Send an Email with User fields data entered in the form


Hi All,

          I have a form which have some user input fields(like textboxes,dropdownlists,textarea etc) fields and a submit button.

on click i need to send email with body contents as all the details entered by user in the form

Can anyone suggest how i should approach to this in sharepoint..

any code examples would be appreciated.


wss2.0 Infopath 2007 'This form requires connections to data sources when it is loaded. At least on


Hi all

I have a user who receives the error 'This form requires connections to data sources when it is loaded. At least one of these connections is not available. As specified by the form designer, this form will not open' when trying to Submit an infopath form located on a WSS2.0 site.

The user has been having this issue since upgrading to Office 2007 and IE7. I have had the user run an Office Diagnostics but this has not resolved the issue.

I am not aware of any other users experiencing this issue.

Any ideas please?

Got form Data... Now what?


I have an infopath form submitted to a form library that my users have been submitting data to.  This is working out just fine.


My problem is that I need to view the submitted data is a more readable format such as PDF or some other format.  In addition to this I need to create this type of format for archival purposes.


Has anyone any ideas on this subject or have any suloutions on how to accomplish this?


Thank you for your thoughts.




Data form web part not displaying - Unable to display this Web Part. ....



I am designing a data form - adding some formatting etc.  I am able to see the webpart correctly in SPD split view, but when I trying to preview it, it gives me the following error

Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Windows SharePoint Services-compatible HTML editor such as Microsoft Office SharePoint Designer. If the problem persists, contact your Web server administrator.
ANy help would be welcome, I have spent a lot of time on this page and don't want to do it again.  THere are a lot of fields and it's a tedious process to move them to the correct location.  I am at my wits end, I am not sure how to debug this!!


Transfering Data from Windows form application to a website

Hello Friends I have a windows form application and i have to transfer the data from my forms that have been retrieved from SQL server database to a website. So that i can automate the data entry on the website. Can anybody please tell how should i go about doing this. Thanks & Regards, Syed

Customizing pages with Asp.Net Dynamic Data Domain Service Web Applications?

Hola, It used to be so easy creating new folder under CustomPages with the (Entity/Table name) and copying on it all base default PageTemplates (Details, Insert, Edit, List and ListDetails) and you will get access to those pages only for the specific table (this was the default automatic behavior of the Dynamic Data framework) When it comes to be using Asp.Net Dynamic Data Domain Service Web Applications it seems that we need to learn a new way of doing this because it is just simply different and you got a lot of errors when compiling your application if you do this the old way? What might be the new way, uh? HOW DO WE DO THIS NOW ... I MEAN ... CREATING DEFAULT CUSTOM PAGES FOR SPECIFIC TABLES (Details, Insert, Edit, List and ListDetails) with Asp.Net Dynamic Data Domain Service Web Applications? The problem arises when the definition for your newly created classes is absent from the automatically generated code when you created your domain service !!!!! . If you simply copy the PageTemplates as they are, you got a duplicated error message because the new .designer file (automatically generated) conains the definition of the class you are copying (not the newer one) so even if you rename your .aspx file the result is not what you would normally expect (the .designer class is not regenerated after renaming). The .designer file keeps the domain service definition and if y

How to save form data to delimited file?

I tried searching, but maybe I was putting in bad keywords =\How do I go about saving form data into a delimited file?

Passing data to the client and back - best way?

I'm ok (I think) with using a data bound Custom Control on the server to get hold of my data (it will be part of a larger dataset) and to ultimately pass updates to the database.  The bit I'm researching at the moment is passing that data to and from the client. One way to pass the data to the client is to use JSON within the Pageload event to construct a set of Javascript objects (one per row in the data).  Is that the best way, or am I missing something? Then, after the data has been manipulated on the client, I need to pass the rows back again so that the server side code can pick them up and process the updates.  I've seen a suggestion on here that a hidden text field is one way to do that.  Is it the best? Neither of my approaches seem to be at all elegant - and I suspect that I am missing something fundamental in ASP .NET AJAX! Thoughts welcome, Thanks, Nick

Passing data from a DetailsView to an Applet

I have a DetailsView that I am trying to use to pass results to an applet's parameter list but I can't figure it out. Example: <asp:DetailsView ID="..."....     <Fields>         <asp:boundfield Datafield="Name".../>         <asp:boundfield Datafield="Name2".../>          ...etc.   <applet codebase="http:/..." ...> param name="Name" value="value of Name from my DetailsView" /> param name="Name2" value="value of Name2 from my DetailsView" /> ...etc. I have been trying all sorts of things and viewing tutorials, etc, but I just don't seem to be able to figure this out.        

Passing return value from a Web Service to a label in a Form View

I am using JavaScript to call a web service. The JS is correctly receiving and passing the web service information. At the moment, the web service returns a country name as a string to a JavaScript alert pop up box as follows:ret = CountryRegionsWebService.GetTranslatedCountryShortName(ddl1_value, ddl2_value, OnComplete, OnTimeOut, OnError);function OnComplete(args) { alert(args); } I want to change this so that web service returns the country name to a label inside an insert item template of a form view. Is there a way to pass in the label variable to the OnComplete function signature and still account for the variable args?, such as: Server Side Declaration of JavaScript ddl2.Attributes.Add("onChange", "JavaScript:OnComplete('" + lab5.ClientID + "', '" + "args" + "');"); Client Side JavaScript function OnComplete(lab5_id, args) { var lab5 = document.getElementById(lab5_id); lab5.innerHTML = args; }  
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