|
I said ones who can help most. Mine is not helpful to problem
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
Can you post some simple case code that demonstrates the problem?
|
|
|
|
|
SomeDomain/AddLineup.aspx?&Cname=Yogesh&Contact1=NA&Contact2=NA&DataCenter=NA&Distt=NA&Activity=NA&School=NA&ActivityDate=NA&ALocation=NA&VisitTime=NA&DateVisit=NA&VisitCenter=NA&CourseInt=NA&Comments=NA&TransferBy=NA
Hi i want to call a url like i mention above. Its working fine when i run the same through debug.
But when i upload the same on my webserver it give me the error.
System.NullReferenceException: Object reference not set to an instance of an object. at AddLineup.InsertRecordLinedUp()
Here InsertReceordLinedUp is a function in AddLineup.aspx page.
Plz Reply.
Thanks
Yogesh Agarwal
|
|
|
|
|
That means you are referencing an object in InsertRecordLineUp , which you have in your development machine but it does not exist in your webserver.
|
|
|
|
|
|
Why posting at multiple forums? You did in Q&A. Stick to that.
|
|
|
|
|
i want to check my broswer
so i want this fuction to execute just one or little time.
but This code don't stop reading page.
below is source
//////////////////////////////////////////////////////
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>회원조회 페이지</title>
<script type="text/javascript" src="/BrowserCheck.js"></script>
<script type="text/javascript">
function a()
{
document.getElementById("txt_broswer").value =
document.getElementById("txtSubject").value = " koko ";
form1.submit();
}
//check_Select();
</script>
</head>
<body style="text-align:center" onclick="a()">
<form id="form1" method="post" action="Default.aspx" >
<input type="text" id="txtSubject" name="txtSubject" value="test" />
<asp:Label ID="Label1" runat="server" Text="Label" ></asp:Label><br />
<input type="hidden" id="txt_broswer" name="txt_broswer" value="test" "/><br />
</form>
</body>
</html>
///////////////////////////////////////////////////
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
string jung = Request.Form["txtSubject"];
Label1.Text = "returnvalue1 " + jung;
return;
}//if postback
}
hi
My english is a little.
anyway, nice to meet you~~
and give me your advice anytime~
|
|
|
|
|
buffering83 wrote: this fuction to execute just one or little time
Which function? What do you mean 'little time'
buffering83 wrote: but This code don't stop reading page.
What do you mean?
also, format, format, format the source code you post here
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
The relevant code must be in BrowserCheck.js. Can we see that please? But only if you put it in a code block so we can read it.
|
|
|
|
|
Hi guys am trying close the browser window once user clicks button 'Exit browser',
in asp.net
I tried the following but it won't work
string scriptor = "<script type=javascript>window.close();</script>";
if(!ClientScript.IsStartupScriptRegistered("clientScript"))
{
ClientScript.RegisterStartupScript(Page.GetType(), "clientScript", scriptor);
}
and
Response.Write("<script type=text/javascript>self.close()</script>");
this is in my click event
Does anyone know how i can fix this one?
please help
|
|
|
|
|
What happens if you add an 'onclick' attribute to your button as set is equal to window.close();
Seems a bit unnecssary to require a postback to the server for this.
|
|
|
|
|
Try this:
string script = "window.close();";
System.Web.UI.ScriptManager.RegisterClientScriptBlock(Page, this.GetType(), "CloseWindow", script, true);
This should work.
|
|
|
|
|
Hi thanks Sandeep,
Well, this works for IE but unfortunately it won't work for Fire Fox
for some reason...
|
|
|
|
|
Respected
How we Import ExcelSheetData into SqlServer2005 Table,by using Asp.net with C# .
Thanks.
|
|
|
|
|
Rather convert your file into .csv(comma delimeted file) and use bulk insert like:
USE your_database_name
Go
BULK INSERT [your_table_name]
FROM 'C:\FolderName\FileName.csv'
WITH
(
FIELDTERMINATOR=',',--this means that your fields(columns) are separated by commas
ROWTERMINATOR = '\n'--and it says that new line is a row terminator
)
GO
From Excel, go File > Save As > Save As file type, look for csv
Good luck.
|
|
|
|
|
I have installed Windows 7, VS2010 and .NET40
I'm getting the error below.
Error Summary HTTP Error 500.19 - Internal Server Error The requested page cannot be accessed because the related configuration data for the page is invalid. Detailed Error Information Module IIS Web Core Notification Unknown Handler Not yet determined Error Code 0x80070032 Config Error The configuration section 'system.web.extensions' cannot be read because it is missing a section declaration Config File \\?\C:\inetpub\wwwroot\web.config
i am confused as to what this means. because i have the <system.web.extensions> in my web.config. thanks in advance for helping out.
|
|
|
|
|
Check the permissions for your web site.
me, me, me
"The dinosaurs became extinct because they didn't have a space program. And if we become extinct because we don't have a space program, it'll serve us right!"
Larry Niven
|
|
|
|
|
A detailed answer can be found here[^], along with screen shots, detailing the fix.
Basically, IIS is set up so that the DefaultAppPool is running under .Net 2.0 and you need to change it to run under .Net 4.0
|
|
|
|
|
Thanks for attending to my question. i guess i figured it out and it's working fine now.
I did have an error in my web.config file, which when fixed worked fine.
I had to change the true in compilation debug="true"' tag with false
So instead I declared it with false and it worked.
|
|
|
|
|
Hi,
I want to send a message to the parent page when a button is click on the ascx control.
How can i accomplish this?
Thanks
|
|
|
|
|
form ascx page button click do something like this.
parent.document.getElementById("ParentControlID").value="your message";
Raju.M
|
|
|
|
|
|
in ascx codebehind add
protected void Page_Load(object sender, EventArgs e)
{
Button1.Attributes.Add("OnClick", "javascript:alert('your message');");
}
try and tell us how it worked
|
|
|
|
|
Hi
I have a gridview which has button that allows a user to click and download an xml file stored else where using force download - Response.AddHeader whether.
However, whilst this all works fine, when file is downloaded it prompts the user to save the file first and then opens the saved file in a new window. What I want to do is not to save the file first, but to immediately open the file in a new window without saving. I have tried all sorts of things, but none have satisfied the design I want to implement.
Thus:
1) Response.ContentType = "Applicaton/vnd.ms-xml"; This cause the user to save the file first before opening in a new page
2) Response.ContentType = "text/xml"; Opens in the window without saving first but opens in the existing window without allowing the user to go back to the gridview from where they clicked.
Does anyone have a way round this where I can open in a new window without saving?
Thanks
|
|
|
|
|
Create a separate page for Xml. Use window.open from the GridView Click where you can use your Xml writing logic.
|
|
|
|