473,327 Members | 2,081 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Error: 'null' is null or not an object

Hi All...
Any one help me with the above weird error

I have a code like below

Expand|Select|Wrap|Line Numbers
  1. print <<"HTML";
  2. Content-type: text/html
  3.  
  4. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
  5. <html lang="en">
  6. <head>
  7.  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  8.  <meta http-equiv="pragma" content="no-cache">
  9.  <meta http-equiv="expires" content="-1">
  10.  <meta http-equiv="cache-control" content="no-cache">
  11. HTML
  12. print <<"END_OF_HTML1";
  13. <script language="JavaScript" src="get_job_var.js"></script>
  14. <script language="JavaScript" src="get_func.js"></script>
  15. <script language="JavaScript" src="js/emp.js"></script>
  16. </head>
  17. END_OF_HTML
  18.  
  19. prn emp();
  20.  
  21. print <<"END_OF_HTML2";
  22. <tr><td width="100%">
  23. <form name="empForm" method="POST" action="body.pl" target="s_body" onSubmit="return ValidateForm(this);">
  24. <table width="100%" border="1" style="font: 8pt Arial, Helvetica">
  25. <thead>
  26.     <tr bgcolor="#CAD7EA" >
  27.         <th align="center">EMP Criteria</th>
  28.     </tr>
  29. </thead>
  30. <tbody id="tbody_30" style="display:" >
  31. END_OF_HTML
  32.  
Below this there are some more functions that is used to select some options and then submit the report

Now I want to get rid of prnemp() and use only [HTML]<body onLoad="initParam(empForm);"><script language="javascript">top.menufr.MSG = "$msg";</script>[/HTML]
to initialize the parameters. So, when I try to place the above 3 statements in between the END_OF_HTML1 and END_OF_HTML2, Its giving the msg like "Error: 'null' is null or not an object

Plzz help me :)

sub prnemp()
{
[html] <body onLoad="initParam(empForm);">
<script language="javascript">
top.menufr.MSG = "$msg" ;
</script>

<table width="100%">
<tr><td width="100%">
<table width="100%" border="1">
<thead>
<tr bgcolor="#CAD7EA" >
<th colspan=3 >
<table cellspacing=0 cols=2 width="100%" style="font: 8pt Arial, Helvetica">
<tr>
<th nowrap=1 align="left"><DIV onclick="ButtonClick('pc');"><img id="expimg" src="image/Collapse.gif">&nbsp;&nbsp;Quick Count -- $emp</DIV></th>
<th nowrap=1 align="right">($empCode)</th>
</tr>

<tr>
<th nowrap=1 colspan=2 align="right">Last Update: $LastUpd</th>
</tr>
</table>
</th>
</tr>
</thead>

<tbody id="tbody_qc" style="display:none" >

<tr bgcolor="#F1F1F3">
<td NOWRAP=1>Summary</td>
<td align=center># of<br>Surveys</td>
<td align=center>% of<br>Surveys</td>
</tr>

<tr bgcolor="#F1F1F3">
<td NOWRAP=1>Scores</td>
<td align=center>$emp</td>
<td align=center>$prcnt</td>
</tr>[/HTML]
}
Mar 19 '08 #1
2 1951
Please help me to get rid of the above problem
Mar 19 '08 #2
acoder
16,027 Expert Mod 8TB
You have a space between prn and emp() when calling prnemp().

PS. 48 minutes is not nearly enough time to try and bump up your question to the top. You just disadvantage yourself by removing it from the unanswered list.
Mar 20 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Robin Dindayal | last post by:
Does anyone know how I can print a fully rendered .aspx to the server's printer? I know that, if I wanted to print to the client's printer it would be easy (ie. use javascript's window.print()). ...
4
by: Larry Tate | last post by:
I am wanting to get those cool html error pages that ms produces when I hit an error in asp.net. For instance, when I get a compilation error I get an html error page that shows me the ...
3
by: Adriano | last post by:
Hello, when I try to print something, either DataGrid or from Crystal Report viever the folowing error message appears and cancels printing: Object reference not set to an instance of an...
3
by: Doug Durrett | last post by:
I'm having an issue and wanted to pass it by everyone to see what you think. Here is my code. //Code Start searchs = new...
3
by: Jeremy Chapman | last post by:
I've writtin a very simple web service in axis which returns an array of classes. I consume it in a .net app. When receiving the response, my .net app generates an error "Cannot assign object...
2
by: arun1985 | last post by:
In the project i am using i am having the following code and when i upload it to the server.Its givig me the following error in the global.cs file. Server Error in '/' Application. ...
0
by: shahiz | last post by:
This the error i get when i try to run my program Error: Unable to realize com.sun.media.amovie.AMController@18b81e3 Basically i have a mediapanel class that initialize and play the media as...
3
by: suganya | last post by:
Hi Some professionals already has developed the project using menu. In my company, they have given me task to clear the error in that. It is a script file named as "menubarAPI4.js" which is kept...
11
by: xenoix | last post by:
hey there, im reasonably new to C# and im currently writing a backup application which im using as a learning resource. My PC :- Visual Studio 2005 .NET Framework 2 Component Factory Krypton...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.