|
I'm getting this error from a page that has been edited. Neither the aspx nor the code behind files are asking for this field any longer, and the stored procedure has been changed and does not include the field. Why is it falling over on the live server? It runs perfectly well on my local machine in debug? Is there some kind of caching in IIS that I need to flush in order to use the new version of the pages?
Any suggestions as to where to look?
|
|
|
|
|
Did you remember to upload the compiled .dll to your live server? If you just sent the .aspx then you've not updated the code-behind.
|
|
|
|
|
I've been using the Visual Studio "Copy Website" option, copying the aspx and aspx.cs files - never had a problem before...
OK - I've just tried an iisreset and same result - I think the issue may be that I have a cached binary somewhere (perhaps on the ISA server).
modified on Tuesday, February 19, 2008 8:43 AM
|
|
|
|
|
Resolved by deleting the files from the server and re-publishing. Still not sure where the old files were being cached.
|
|
|
|
|
I want it like this: when users try to access some page, if the page is login.aspx or permitted by role, then let it go; but when it's denied by role config, I want kept signed in and to a warning page.
For now, it's forced to sign out and redirect to login.aspx.
|
|
|
|
|
Friends,
I want to hide the item of last row named(Down) inside my gridview. It is a linkbutton. I have already done how to hide first row but I don't understand how can I find the last row or total rows inside the gridview.
To hide the first row I am using following method
< asp: linkbutton ID="lblUp" runat="serveR" Font-Underline="true" ForeColor="blue" Text="Up" Visible="<%# IIf(CType(Container, GridViewRow).RowIndex = 0, false, true) %>" CommandName="MoveUp" CommandArgument="<%# Container.DataItemIndex %>" >
Please note that I am using this linkbutton in Item Template.
Please help me in this regard.
|
|
|
|
|
Please
1 - don't double post
2 - use a header that makes sense
You will need to store the number of rows in your data source, or the size of a page, then you can write similar code to work based on that data. Without the row count, you're kind of hosed.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Friends,
I want to hide the button named down inside Item Template on last row. How can I do this.
For first row I have done this
<asp:templatefield>
<itemtemplate>
<asp:linkbutton id="lblUp" runat="serveR" font-underline="true" forecolor="blue" text="Up">
Visible="<%# IIf(CType(Container, GridViewRow).RowIndex = 0, false, true)>" CommandName="MoveUp" CommandArgument="<%# Container.DataItemIndex %" >;
Now the same code I want to use to hide last row in Grid View. How can I do this.
|
|
|
|
|
hi Zeeshan Memon,
I think answer exists in your question only.
Zeeshan Memon wrote: <asp:linkbutton id="lblUp" runat="server" font-underline="true" forecolor="blue" text="Up">
Visible="<%# IIf(CType(Container, GridViewRow).RowIndex = 0, false, true)>" CommandName="MoveUp" CommandArgument="<%# Container.DataItemIndex %" >;
You should find RowCount of your gridview because your gridview is 0 based indexed. Just need to check index is RowCount-1 OR not then you show and hide your control.
<asp:linkbutton id="lblUp" runat="server" font-underline="true" forecolor="blue" text="Up"><br />
Visible="<%# IIf(CType(Container, GridViewRow).RowIndex = CType(Container, GridViewRow).RowCount -1, false, true)>" CommandName="MoveUp" CommandArgument="<%# Container.DataItemIndex %" >; <br />
Hope this will help you.
Thanks & Regards
Dilipv
|
|
|
|
|
Dear all,
Here i have developed an application in .net using vb.
My problem in my appilcation some forms are having postback events or selectitemchanged and so on.when the event is takes place the page is postback and the form appears.But while i am implementing at the client end,it is opening very slowly.
What might be the reason??and wat i have to do for fast access??
Theres no use if the appln is slow.
Pleasse give me some suggestion
Thaks in advance.
kissy
|
|
|
|
|
If it's fast foryou and slow for them, perhaps the problem is the speed of a database connection ? Or something like trying to connect to a database that exists on your machine and not theirs is causing the code to wait for a timeout
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello!
When I set enableviewstate="false" on my select-control its always empty on a postback. Shouldnt I be able to get hold of what´s displayed in the select-control? To clarify, my problem is this:
* I populate my select-control
* I choose on of the options and press a button with autopostback set
* When I'm at serverside the select has no value set
|
|
|
|
|
Do you know what viewstate is ? You turned it off, and so it's not there. Therefore, your value is not there.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello all
In my application i am creating a word document based in user
responses. Now i want to send the document as an attachment with the
mail as soon as the document is created. I want to send email in b
background. As soon as document is created i want to send mail
containing document as an attachment.
How can i do this? Please help me to solve..
I am creating document by two ways.
1) StringBuilder class.
2) Exporting datagrid to document.
Thanks.
Rahul
People Laugh on me Because i am Different but i Laugh on them
Because they all are same.
modified on Tuesday, February 19, 2008 8:08 AM
|
|
|
|
|
Create an instance of the Attachment class and add it to the
MailMessage.Attachments collection.
Best Regards
-----------------
Abhijit Jana
Microsoft Certified Professional
"Success is Journey it's not a destination"
|
|
|
|
|
Hi
can u tel me how can i create instance of Attachment class.
People Laugh on me Because i am Different but i Laugh on them
Because they all are same.
|
|
|
|
|
Hi
can u tel me how can i create instance of Attachment class.
Thanks.
Rahul
People Laugh on me Because i am Different but i Laugh on them
Because they all are same.
|
|
|
|
|
Hi Rahul!
Suppose "attachement" is a "StringBuilder" type then
ObjMail.Attachments.Add(new MailAttachment(attachement));
I hope this will help you..
Regards.
|
|
|
|
|
Hi
I have tried that but it gives following error message.
Out put can not produce a value
my code is for attachment is
emailAttach = New MailAttachment(Response.Write(oStringWriter.ToString())<br />
People Laugh on me Because i am Different but i Laugh on them
Because they all are same.
|
|
|
|
|
hi all
i m printing a .aspx page for that i m using
<br />
<script language="javascript"><br />
function Pprint()<br />
{<br />
<br />
var contents = document.getElementById("divprint");<br />
var printPage = window.open('','','left=5000,top=5000,width=1,height=1,toolbar=0,scrollbars=0,status=0, visiblity = hidden');<br />
printPage.visible = false ;<br />
printPage.document.write(contents.innerHTML);<br />
printPage.document.close();<br />
printPage.focus();<br />
printPage.print();<br />
printPage.close();<br />
<br />
<br />
}<br />
</script><br />
<br />
<br />
<input type="button" style = "background-color:darkGray;font-weight:bold;" id = "btnHtmPrint" value = "Print" onclick = "Pprint();" runat="server" /><br />
now how do i set page options in c# like page size, margin etc..
Amit Metkar
3i-infotech, Mumbai.
modified on Tuesday, February 19, 2008 5:39 AM
|
|
|
|
|
Amit.Amit.Amit... wrote: how do i set page options in c# like page size, margin etc.
You can't do that. Those are user specific settings in tbe browser.
The only possible way to programmatically change those settings would be to run an ActiveX control in the browser so that you could access the registry of the client computer.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
I have this web page that displays fine with internet explorer but when you open the same web page in mozilla firefox the display becomes very bad and again if you open that same page using another screen resolution,you get a distorted web page very different from what you had.
Please do anybody have a solution to this problem?
|
|
|
|
|
The page is actually displayed correctly in Firefox, and incorrectly in Internet Explorer. It's a common misconception that Internet Explorer is the standard just because it's the most commonly used browser, but the standards are issued by W3C[^]. Although Microsoft is a member of this organisation, their browser doesn't do a very good job at following the standards.
There is no easy solution. You have a page that relies both on the rendering errors in Internet Explorer and a specific window size to render as intended. You have to rebuild the page so that it circumvents the rendering errors in Internet Explorer rather than relies on them.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Hello Everybody,
I have an application where I have to store some values in Session variables.
And later on I need to use those values in a JavaScript function.
Can anyone tell me how to access Session values in JavaScript or some better approach to this situation..
HappyCoding
|
|
|
|
|
var sessionValue = <% Session["value"].ToString() %>
|
|
|
|