|
Hi, I am using CheckBoxList control, and i want user to re-arrange the items in the listbox on his preferences.
I want to use javascript for the same so that no postback occurs.
Can someone please help me out.
Thanks and regards,
Deepak
|
|
|
|
|
You want to do this with the actual list ? I'm sure this can be done, web parts do it pretty much, but it sounds like a lot of work to set up, especially if you expect it to work cross browser ( may not be possible ).
The core issue IMO is that you have a CheckBoxList, if it's rendered and then you change the order, I am not sure that the postback will be able to restore the list from view state ( because you'll have changed the order of controls ).
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I need to use javascript only.
And i have already disbled viewstate of the page.
|
|
|
|
|
Then how will your selected order persist between page views ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
hi all i just want to knw hw to use and implement ASP.Net Role-based Security in ASP.Net Application
thank u all
abdelhameed81
|
|
|
|
|
|
Hi,
I am using asp.net 2.0 , in the master page i have a asp control that is a hidden field .
in onload function i am calling the javascript to the set value of the hidden field to 'false'
but that java script is not getting the hidden field control.
I need to access that control in onload event.
how i can do this or is there any other way
please help.
deepak
|
|
|
|
|
What do you mean by an 'asp control' ?
Remember, if you're doing any sort of includes in the master page, the path needs to be relative to the page which consumes the master page, not the master page location. Absolute paths seem the only viable way to do this.
The master page has a Page property, from which you can access the ClientScript class to call RegisterStartupScript ( this is all from memory, but the names are the only bit that may be wrong ). If you call this, your javascript will be inserted at the end of your page, which means that your hidden control is guarenteed to be visible to it.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Ok, basically I want the user to enter in items in a form and then click a button to post the page to another server. A regular form would be great, but the problem is, I also have to send secure credentials to the other server.
I don't want to put them in hidden fields since a View Source would reveal them.
Is there a way to post to a server from the Code Behind, yet have the User end up at the other server?
I have tried using the WebRequest class, then get the WebResponse and do a Response.Write to write the results to the browser. The problem with this is that it tries to resolve thinks like includes, images, and the other server's form ACTION tag to my server. So none of hte images show up and posting their form breaks too.
Did that make sense? Basically I just want to do a form post from my code behind and send the user to the other server along with the form post.
any help would be great, so far everything has been a dead end!
|
|
|
|
|
Any reason why you are not storing the credentials in a cookie?
If you set an expiration for a cookie, it will get saved to the user's computer, but if you don't set an expiration there is no way (that I know of) that the cookie can ever be seen by a user.
|
|
|
|
|
I am sending the request to a third party payment processing site. Unfortunately I have no control over their servers
|
|
|
|
|
I'm using Visual Studio 2005 and SQL Server 2005 on a Windows Server 2003 operating system. I'm trying to print Reporting Services Reports dirctly to the printer without using the Report Manager to preview. I'm using some VB.NET code that was posted here at the following location:
http://www.codeproject.com/vb/net/RSPrintLandscape.asp
I have an ASP.NET application that I'm running on a local machine to locate and print reports from a remote report server on another machine. The application downloads a report in PDF format and creates a file on my local machine successfully, but when it tries to write to the file I get the following error:
***********************************************************************
Server Error in <myappname> Application.
Access to the path 'C:\TEMP.PDF' is denied.
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.
Exception Details: System.UnauthorizedAccessException: Access to the path 'C:\TEMP.PDF' is denied.
ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity. ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6) that is used if the application is not impersonating. If the application is impersonating via <identity impersonate="true">, the identity will be the anonymous user (typically IUSR_MACHINENAME) or the authenticated request user.
To grant ASP.NET access to a file, right-click the file in Explorer, choose "Properties" and select the Security tab. Click "Add" to add the appropriate user or group. Highlight the ASP.NET account, and check the boxes for the desired access.
Source Error:
Line 256: WebFile.Credentials = CredentialCache.DefaultCredentials
Line 257: 'Create the local file
Line 258: LocalFile = New FileStream(DestFilename, FileMode.Create)
Line 259:
Line 260: 'Download the file in 16k chunks
Source File: C:\Projects\ICISMainReport2\PrintDirect.aspx.vb Line: 258
Stack Trace:
[UnauthorizedAccessException: Access to the path 'C:\PRINT_TEMP.PDF' is denied.]
System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +2013027
System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy) +998
System.IO.FileStream..ctor(String path, FileMode mode) +65
PrintDirect._PrintDirect.DownloadWebFile(String URL, String DestFilename) in C:\Projects\ICISMainReport2\PrintDirect.aspx.vb:258
PrintDirect._PrintDirect.btnPrint_Click(Object sender, EventArgs e) in C:\Projects\ICISMainReport2\PrintDirect.aspx.vb:207
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +105
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +107
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102
******************************************************************************
I considered the suggestion that was listed with the error message but please note that this file is created on the user's machine each time the application is run. How can I control permissions for a file on each user's machine?
Any suggestion how I might overcome this problem?
Thanks
RickyZX
|
|
|
|
|
Hello all,
Sub: Duplicate Mails - Generated on press of Refresh button in Browser.
HOW TO VALIDATE THIS IN ASP not ASP.NET.
We created a application code using asp vb script which sent mail with attachment once the people proceeds for order.
The problem we are facing is we are getting duplicate mail after once we refresh the confirm button.
so we are getting more mails when ever we refresh the pages. This should be stopped.
Please advice.
Thanks and Regards,
kris
If you fail for the first time , call it version 1.0.
|
|
|
|
|
krishna19 wrote: HOW TO VALIDATE THIS IN ASP not ASP.NET.
So why post it here ? It belongs in 'web development'.
krishna19 wrote: so we are getting more mails when ever we refresh the pages. This should be stopped.
I'm sure it should. Your code to send email is obviously being run more than once. No-one can comment further without seeing the code, and the code should be seen in the web dev forum, not here.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I have the following connection in my webconfig file:-
<add name="Conn" connectionString="Data Source=C:\inetpub\wwwroot\quetzal_system\equipment.mdb" providerName="Microsoft.Jet.OLEDB.4.0"/>
Can someone just check it's correct never done one only sql.
|
|
|
|
|
|
Sorry about the couple of closley related Q's thisafternoon... but I'm just getting to grips with atlas.
Is it possible/feesable/sensible to have a master page and load all its content pages sans-postback, Atlas style.
As the site im working on only has 2 pages and a master.
1 page uses Atlas and an XML control and XSL to mimic being 3 or 4 pages that are totaly generated from database queries.
The second does not and having that one page that posts backs kind of upsets the seemless feel i want... I thought of making the second page a custom control on the first page hiding and revealing it inside an update panel when needed but that seems an awefuly clunky way of doing it.
Any ideas?
Thanks.
|
|
|
|
|
Under fire fox the masterpage does not even flicker... under IE there is an ugly refresh on the master page when navigating to pages still under the same master page.
All my graphics have been optimised and saved in super lean formats using photoshops "Save For Web" feature .. yet still IE7 gives this ugly refresh on the master page.
Any ideas?
Thanks.
|
|
|
|
|
I think that you are confusing master pages with framesets. A master page is only a tool on the server to separate contents. The entire page is created for every request, not just the contents from the aspx file.
---
b { font-weight: normal; }
|
|
|
|
|
No i understand the master page to that extent(see my above question about geting the master to load the contents via ajax to counter this very point).
But under fire fox there is no "flicker" during loading of any of the pages... the master page stays (seemingly) un altered/un-re-loading while the content updates...
Under IE7 there is a nasty and pronounced flicker of the whole page
|
|
|
|
|
Yes, that is what happens when you load a page in the browser. The browsers just work differently.
---
b { font-weight: normal; }
|
|
|
|
|
I also know that... BUT there have been plenty of work arounds or "cross-browser" solutions to certain "quirks" of some browsers.
And that was what I was looking for with regards IE7 and masterpages.
|
|
|
|
|
The only work around for the flickering caused by reloading the page would be to update the page without reloading the page.
---
b { font-weight: normal; }
|
|
|
|
|
I have a BoundColumn which shows a Date.In the Sql server database i have Null value, but in the datagrid i see 1/1/0001 12:00:00 AM .Do you know what the cause might be?
If it has any relevance, the datagrid source for the boundcolumn is a LLBLGen Collection.
Thank you.
|
|
|
|
|
You can convert that into date only and then display it in the datagrid.
Best Regards,
Apurva Kaushal
|
|
|
|