473,657 Members | 2,921 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Post-back and user controls

Hello!

How I can force user controls to reload on post-back?

Thank you!
James
Nov 19 '05 #1
3 1292
What exactly do you mean? If the user Control is declared on the page (in
the ASPX file) then it's automatically "reloaded" upon postback. If it's
dynamically added, then you'll have to recreate it yourself manually upon
postback. Here's a sample I posted a while back (it doesn't do user controls,
but they should work just the same):

http://groups-beta.google.com/group/...717a97bd32c450

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hello!

How I can force user controls to reload on post-back?

Thank you!
James


Nov 19 '05 #2
I use some user controls to customise page layout...There are two user
controls that check if the user is authenticated or not and display data
based on this.

My problem is that if I call FormsAuthentica tion.SignOut() it causes
post-back, but other user controls on the page don't detect that the user is
logged-off.

James

"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:59******** **************@ msnews.microsof t.com...
What exactly do you mean? If the user Control is declared on the page (in
the ASPX file) then it's automatically "reloaded" upon postback. If it's
dynamically added, then you'll have to recreate it yourself manually upon
postback. Here's a sample I posted a while back (it doesn't do user
controls, but they should work just the same):

http://groups-beta.google.com/group/...717a97bd32c450

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hello!

How I can force user controls to reload on post-back?

Thank you!
James


Nov 19 '05 #3
> My problem is that if I call FormsAuthentica tion.SignOut() it causes
post-back, but other user controls on the page don't detect that the
user is logged-off.


It's because during the postback to log out you're still authenticated. I'd
suggest doing a Response.Redire ct(Request.Path ) in your event handler when
you detect they want to logout. It isn't pretty, but it works.

-Brock
DevelopMentor
http://staff.develop.com/ballen

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
14036
by: Erik Johnson | last post by:
I am trying to work with a program that is trying make an HTTP POST of text data without any named form parameter. (I don't know - is that a normal thing to do?) I need to write a CGI program that accepts and processes that data. I'm not seeing how to get at data that's not a named form parameter. I wrote a simple CGI program to echo a string representation of the cgi.FieldStorage class that's recevied, and one to make an HTTP POST to it...
15
3120
by: Thomas Scheiderich | last post by:
I am trying to understand Session variables and ran into a question on how they work with data that is passed. I have an HTM file that calls an ASP file and sends the name either by GET or POST. When I find is that if I send the value by the GET method, response.write("From QueryString: " & Request.QueryString("usernamefromform") & "<br><br>")
0
1838
by: Hans Forbrich | last post by:
Section 1. Ballot: ------------------- 1.YES NO: I agree that there should be a periodic post describing the newsgroup charter and providing a FAQ on newsgroup usage. 2.MONTHLY BI-WEEKLY WEEKLY: The post should be transmitted with this frequency.
0
1818
by: Hans Forbrich | last post by:
Section 1. Ballot: ------------------- 1.YES NO: I agree that there should be a periodic post describing the newsgroup charter and providing a FAQ on newsgroup usage. 2.MONTHLY BI-WEEKLY WEEKLY: The post should be transmitted with this frequency.
24
2872
by: moriman | last post by:
Hi, The script below *used* to work. I have only just set up a server, PHP etc again on my Win98 system and now it doesn't? On first loading this page, you would have $p = and the button image below it.
9
3085
by: c676228 | last post by:
Hi, I am new to this discussion forum. I started to post questions on this forum since this Jan. and got many good responses and I am very appreciated to those who are willing to help with their expertise. That save me a lot of time and stress. I want to rate the post, but I only see questions "is this post helpful" and " why should I rate a post" link. I didn't see any thing "rate the post" link. I already sign into the community...
3
4909
by: JansenH | last post by:
We have implemented a 'HTTP Post' client in C# that posts Xml documents to a webserver. This is working fine if the post rate is one post for every 20 seconds. But if the post rate is increased to one post for every 10 seconds the client start getting error 403 'forbidden' from the webserver after a short period of time. The webserver is IIS. The choking of the client/server communication when doing high frequency posting is due to that we...
6
5097
by: Brybot | last post by:
I am trying to allow HTTP POST file uploads to my web service. Currently I have it working perfectly for a SOAP/XML request reading in a byte using MemoryStream/FileStream but I cannot figure out how to encode a file on a POST to the same web service. The definition requires a base64binary encoded file, which I have tried. The form is also using a mutlipart/form-data enctype, but I either get a 500 error or 'Request format is invalid'. ...
10
15689
by: Peter Michaux | last post by:
Hi, All Ajax libraries I've read use encodeURIComponent() on the name- value pairs extracted from forms before POST ing the result to the server with and xmlhttprequest. I can understand why this encoding is required in the case of a GET request and the form data is attached as a URI query string; however, why is the encoding necessary for POST requests? Thanks,
9
1351
by: CindyH | last post by:
Hi Trying to get this code to work for http xml post. I need the post to be xml (doc.outerxml) sent in single key name as stream. The following is the post code and code for receiving the request. When it hits the "myresponse = myrequest.GetResponse()" in the post code - I'm getting following error: "The remote server returned an error: (500) Internal Server Error". I don't know if I have something wrong with the post or receiving it on...
0
8385
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8303
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8821
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8723
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8502
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8602
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7316
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6162
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
2
1601
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.