|
Manish_84 wrote: ((UpdatePanel)ContentPlaceHolder1.FindControl("UpdatePanel1")).Update();
But it still refreshing content pages.
You just wrote a code here to update/fire your Content page update panel in line 1 and in line 2 you are asking why is it refreshing. Is there a typo?
Secondly, if you wanted just your content page to refesh, why are you writing your code of updating the update panel in Master page? Is the trigger to update content page present in Master page?
|
|
|
|
|
Yes. I am also confused from his post Cheers !
Abhijit
Codeproject MVP
|
|
|
|
|
Assuming you have everything else correct, do you have a ScriptManager control on your page?
I avoid AJAX when I can (never had the time to climb the learning curve) but when I get pages behaving like a normal ASPX page, it is usually because I didn't include the manager.
|
|
|
|
|
Hi..
In my project while i m running the application...whn i m going a particular aspx page and thn click the enter button of keyboard the page is redirecting to another how to stop this without javascript.I need code for this.
Thanks in advance.
With regards.
Ch.Gayatri
|
|
|
|
|
Ch.Gayatri Subudhi wrote: .whn i m going a particular aspx page and thn click the enter button of keyboard the page is redirecting to another
I guess, on that page there are some default control has been set, and which used to redirect you page to another page. As this is the default control and also Focused, so when some one Press Enter Enter key, it is redirecting to another page.
As you don't want to use JavaScript, You can cange the default control of that page. Or focus any control which is not redirecting to any page.
Hope you got my point. Please let me know if you need any help.Cheers !
Abhijit
Codeproject MVP
|
|
|
|
|
But in my whole application i used default button in log in page...but where in other page its redirecting to other.while clicking enter button of keyboard.
|
|
|
|
|
Ch.Gayatri Subudhi wrote: But in my whole application i used default button in log in page...but where in other page its redirecting to other.
What does it mean? I didn't get your point.
As I already suggested, if Default button is not necessary, you can create one blank control (may be textbox),hide it and focus it on page load. Cheers !
Abhijit
Codeproject MVP
|
|
|
|
|
Sir even though i used javascrip where in my app i used masterpage...still its not working
|
|
|
|
|
Ch.Gayatri Subudhi wrote: Sir even though i used javascrip where in my app i used masterpage...still its not working
What you have done with javascript ? Can you please show us the code ?Cheers !
Abhijit
Codeproject MVP
|
|
|
|
|
<script language="JavaScript">
function disableEnterKey(e)
{
var key;
if(window.event)
key = window.event.keyCode;
else
key = e.which;
return (key != 13);
}
</script>
wrote this in ur masterpage
<body OnKeyPress="return disableKeyPress(event)">
like this i wrote in masterpage
|
|
|
|
|
sir..wht is other way to stop this issue.
|
|
|
|
|
Looks like your page is having a default button specified. Thus on click of it, that defualt button event is called.
Either remove the default button of the page. If you are not setting it or unable to find one the try this:
Use a dummy button in your page and set that button as Default button. Don't attach any handler to it(write reutrn false; in button's OnClientClick) and set the display style or visibility to false.
|
|
|
|
|
But in my whole application i used default button in log in page...but where in other page its redirecting to other.while clicking enter button of keyboard.but i did not sued ant default button to ant other pages accept login page
|
|
|
|
|
looks like you set your Default Button in MasterPage. is that so? that can only carry this to all other pages though you intend to use it in Login page only.
Try putting the default button thing in Login Content page.
|
|
|
|
|
but in my login page it wont hv masterpage...rest of pages i used master page...
|
|
|
|
|
I would provide some input. Please check whether it actually helps in your scenario.
if you are in "Page.aspx" where on keyboard "enter button" hit takes you to "Wrong.aspx". But you actually want to visit "Right.aspx". Please do following steps,
Step 1. In Page.apsx, put "method" and "action" attribute in tag as mentioned here
<form id="form1" runat="server" method="post" action="Right.aspx">
<!-- other existing HTML code for UI -->
<asp:Button ID="Button1" runat="server" Text="Button" />
</form>
Step 2.
in @Page directive in Page.aspx, add "EnableViewStateMac" attribute as the following if not already added
EnableViewStateMac="false"
Step 3. In @page directive in "Right.aspx" as set EnableViewStateMac = false.
Now hitting "enter button" from keyboard while you are in Page.aspx, will always nagivate you to "Right.aspx" instead of "Wrong.aspx".
Please let me know if it helps you.Thanks,
Arindam D Tewary
|
|
|
|
|
while i m running my app...the flow is okay...but whn i clicked the enter button of keyboard i want to stop that action...becoz of that its redirect to anthor page...i need to stay the same page...even i m using masterpage
|
|
|
|
|
Ch.Gayatri Subudhi wrote: but whn i clicked the enter button of keyboard i want to stop that
Did you mean from clicking mouse things are working but you want to stop doing any thing from "keyboard enter button" hit?Thanks,
Arindam D Tewary
|
|
|
|
|
yes sir..how to stop that
|
|
|
|
|
Put this code in your button's onkeypressevent
onkeypress="return eval((event.keyCode==13)?false:true);"
Post back hiting "enter" from keyboard would be stopped but from mouse click flow would be as it is.
Please let me know if it helps.Thanks,
Arindam D Tewary
|
|
|
|
|
Thanks a lot sir..now its working f9..
|
|
|
|
|
You are welcome !!! Thanks,
Arindam D Tewary
|
|
|
|
|
Hi all,
I am using 'Report Viewer Control ' in my project. I am using sub-reports in many cases. Whenever I export such reports containing sub-reports to 'Excel' format which is the major client requirement in our project, the exported excel file shows 'Subreports within table/matrix cells are ignored.'
Can anybody tell me the solution for this? If not possible in reporting service then is there any other way to get data in excel format?
Thanks.
|
|
|
|
|
Use ExcelRecord instead in Excel.
i.e. ExportFormatType.ExcelRecord
for eg:
ReportDocument.ExportToHttpResponse(ExportFormatType.ExcelRecord, Response, true, "Report");
|
|
|
|
|
Till SSRS 2005: This is a known limitation in the excel rendering. The problem occurs when subreports and/or any data regions are nested in table/matrix. Microsoft I mean SSRS doesn’t support exporting these to Excel format.
Other way to get it done is:
Embed the sub report within a rectangle rather than within a table. It will export ok.
P.S.: SSRS 2008 (shipped as part of SQL Server 2008) provides a full solution to this, since it has a new engine and rendering extensions. Excel rendering will now always render subreports contents.
|
|
|
|