|
ASPnoob wrote: do I need to use Response.Redirect() method to successfully send session variables to another page
No
ASPnoob wrote: how do I create and access session variables outside of the pageload method.
similarly as you did now.
Now, overall, you need to understand the concept of Session. First and foremost, it is not page level, it is across the application per user level. For a given user, a session can be created in any page and accessed in any page.
Read about it in much more detail, here:
MSDN: ASP.NET Session State Overview[^]
Exploring Session in ASP.NET[^]
|
|
|
|
|
Session variables are stored on the web server, and are available to that pacticular sessionID number for every page.
|
|
|
|
|
to store into session:
Session["someID"]="Text To Store";
to retrive :
string someString=Session["someID"].ToString();
|
|
|
|
|
No.U dnt need to use it.Because sessions willbe created in web server so whenever you want to access it from any page you can simply access it by using session["sessionid"] collection object....Thank you!
|
|
|
|
|
So, this is probably something I should know how to do anyway but don't... sadly.
I would like to take a project I found here, specifically: http://www.codeproject.com/Articles/460142/ASP-NET-Multiple-File-Upload-With-Drag-Drop-and-Pr and turn it into a control that I can use on an existing website (after changing the save directory and such of course) in the same way I would drop in, say, CKEditor... drop the DLL's in the Bin directory, register it on the page and then lob in a little, <mfu:mfuupload id="somesuch" runat="server"> magic.
So, how would I go about doing that?
For the record, I'm not as lame as this question implies, there're just giant holes in an otherwise brilliant mind.
modified 18-Sep-12 19:48pm.
|
|
|
|
|
|
Hi,
Can anybody help me with requirement. i have a requirement that an .aspx page will contain a static text box and a static button(GENERATE). user will enter number in the textbox say four(4) and click the GENERATE Button,then 4(four) dropdownlist and a button(ADD) will be dynamically created. The dropdown list will contain data like first(1) dropdown will contain value 1,2,3,4...10 and second dropdown will contain 10,11,12....20 and so on. On Clicking the dynamically created ADD button the values of the dynamic dropdowns will be summed and shown in another label that will be dynamically created of the dynamically created ADD button click event.
Thanking you. Any kind Of Help is earnestly solicited.
|
|
|
|
|
Steps:
1. Define a GENERATE Button click handler X
2. In X, get the number provided in Textbox (say y)
3. Define a counter(say z). Set it to one.
4. Code a for loop from zero to y-1 (loop runs y times)
5. Create a dropdownlist inside the loop using new.
- Provide ID
- Define a datasource - a list
- Populate list with fixed 10 numbers starting from z. for first loop z goes from 1 to 10, next 11-20...
- Bind the datasource to dropdonw
- Add the dropdown to the defined panel/placeholder in UI
6. Once for loop ends, create a button (A), define click event and add that too the defined panel/placeholder in UI.
7. for click event of A, do your manipulations as per need.
Try!
|
|
|
|
|
I am trying to build a total image from a series of png files chosen by the user by checkboxes. This will be displayed on a website. I have already successfully done this by using CSS and z indexing for layer heights but now it has been suggested to me to use the bitstream method to compile and display the final picture.
Can anyone tell me which of these methods (css or bitstream) is the most efficient for speed and server resources on the web?
Thanks in advance
|
|
|
|
|
If you are using CSS and creating the image on the client then there is no impact on the server other than, probably, getting the images to use.
"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." Red Adair.
nils illegitimus carborundum
me, me, me
|
|
|
|
|
hi ,
, my website was created with .Net 3.5 , i cant install .Net 3.5 on the server, can i run my website with .net4 on IIS ??
|
|
|
|
|
You can run your website in both .Net framework 3.5 and 4.0. While opening the website in .Net 4.0, you'll be ask to update your website. Depends upon you, whether you want to update the website or continue using 3.5 only.
|
|
|
|
|
hi ,
, my website was created with .Net 3.5 , i cant install .Net 3.5 on the server, can i run my website with .net4 on IIS ??
|
|
|
|
|
I have a textbox(textarea) in which one can write source code in any programming languages, but the problem is that when TAb key pressed instead of giving blank space it gets out from the textbox and move to next element.... So my requirement is that when TAB key is pressed it will give blank space.
Thanks in advance,Any help will be appreciated...!!!
|
|
|
|
|
You should use onkeydown event of textarea to handle tabs.
Refer this link[^] for JavaScript & this link[^] for JQuery.
|
|
|
|
|
Thanks _Amy
|
|
|
|
|
how to apply sorting in grid view field through codebehind.
and my gridview code is:
SqlDataAdapter da = new SqlDataAdapter("select * from newcustomer ", con);
con.Open();
DataTable ds = new DataTable();
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
con.close();
|
|
|
|
|
|
|
My 1: Please read the existing answers and make sure you aren't reposting a link that already exists in another answer.
I wasn't, now I am, then I won't be anymore.
|
|
|
|
|
How to send SMS using Web services ASP.NET C#
|
|
|
|
|
You need API from your SMS provider. Nothing special, just you need to call API function from your web service.
Thanks
-Amit Gajjar (MinterProject)
|
|
|
|
|
I've no idea about it sooo
www.facebook.com/raazak47
|
|
|
|
|
hi friends,
i have a very specific need for my new project and even logical explanation will do the job . I want to show repeated gridview data in a column with seperated commas and i am also using onrowcreated and rowdatabound methods for multiple headers of gridview from this example:
http://www.dotnettwitter.com/2010/12/how-to-create-multiple-row-header-and.html[^]
i also tried grouped gridview example from here:
GroupedGridview - A Customized GridView Control[^]
but this doesnt fix my needs as i want data like this:
database fields/values from query:
Column_groupid | Group_users | designation | Period
58 Matt Admin 5
58 Andrew Admin 5
58 Sachin Admin 5
58 Dinesh Admin 5
59 Sara SuperAdmin 2
59 John SuperAdmin 2
as you can see the name field is changing while others are distinct (which may change but not an issue for now); now i want to display the data in gridview as:
Sr_no | Group_Persons | designation | Period
1 Matt, Andrew, Admin 5
Sachin, Dinesh
2 Sara,John SuperAdmin 2
how can i solve this problem currently i am thinking of using list and filling it in asp:table but i am afraid of performance issues.
thanks & Regards
Alok Sharma
Once their was a rumor, then it became reality...........
|
|
|
|
|
Hello,
I really dont know this will help you or not..
But still i want to give my try..
you can try to get your solution by sql query..
Below to create test table
CREATE TABLE [ForTest](
[id] [int] NULL,
[id2] [int] NULL,
[vak] [varchar](50) NULL
) ON [PRIMARY]
GO
SET ANSI_PADDING OFF
GO
INSERT [dbo].[ForTest] ([id], [id2], [vak]) VALUES (1, 1, N'abc')
INSERT [dbo].[ForTest] ([id], [id2], [vak]) VALUES (1, 1, N'xyz')
INSERT [dbo].[ForTest] ([id], [id2], [vak]) VALUES (2, 2, N'pqr')
INSERT [dbo].[ForTest] ([id], [id2], [vak]) VALUES (2, 2, N'mno')
and below query to get result as per you wish..
SELECT
distinct P.id,
STUFF
(
(
SELECT ',' + vak
FROM ForTest M
WHERE M.id = P.id
ORDER BY id
FOR XML PATH('')
), 1, 1, ''
) AS Models
FROM
ForTest P
Hope this will work for you...
KiranKumar Roy
|
|
|
|