473,503 Members | 1,700 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Log Parser chart output using ASP.Net

I'm trying to write an ASP.Net app that uses Log Parser 2.2's COM interface to
read some Windows Media Server (W3C) log files and generate a chart (GIF file)
on the web server. I'm getting an error when attempting to generate the chart
using the ExecuteBatch method:

Error executing query: Unexpected internal error calling chart object method
ExportPicture: Exception occurred. [Exception occurred.]

Office 2003 Web Components is installed and other output types (XML) work just
fine. So I'm guessing this is a permissions or registration error w/OWC, but not
sure. Hoping someone can point me in the right direction.

Here's the ASP.Net code:

Dim sPath As String = Request.PhysicalApplicationPath
Dim inputContext As New MSUtil.COMW3CInputContextClass
Dim outputContext As New MSUtil.COMChartOutputContextClass

outputContext.chartType = "BarClustered"

Dim query As String
query = "SELECT [c-ip], COUNT(*) AS [Sessions] INTO '" & sPath & "delme.gif'
FROM '" & sPath & "WMS_ISAPI_20040826.log' GROUP BY [c-ip]"

Dim lg1 As New MSUtil.LogQueryClass
lg1.ExecuteBatch(query, inputContext, outputContext) '<-- Error occurs here
Apr 20 '07 #1
2 4693
Did a little more playing around. Turns out if I specify the destination as
something like c:\temp\delme.gif it works, but if there are any spaces in the
file path it fails (c:\temp temp\delme.gif). Strange thing is that spaces in
the path doesn't affect the reading of the log file!

So now the question is how to get this to work with spaces in the path...
already tried enclosing it in quotations (same result.)

"Mike Lowery" <se******@mouse-potato.comwrote in message
news:OC**************@TK2MSFTNGP03.phx.gbl...
I'm trying to write an ASP.Net app that uses Log Parser 2.2's COM interface to
read some Windows Media Server (W3C) log files and generate a chart (GIF file)
on the web server. I'm getting an error when attempting to generate the chart
using the ExecuteBatch method:

Error executing query: Unexpected internal error calling chart object method
ExportPicture: Exception occurred. [Exception occurred.]

Office 2003 Web Components is installed and other output types (XML) work just
fine. So I'm guessing this is a permissions or registration error w/OWC, but
not sure. Hoping someone can point me in the right direction.

Here's the ASP.Net code:

Dim sPath As String = Request.PhysicalApplicationPath
Dim inputContext As New MSUtil.COMW3CInputContextClass
Dim outputContext As New MSUtil.COMChartOutputContextClass

outputContext.chartType = "BarClustered"

Dim query As String
query = "SELECT [c-ip], COUNT(*) AS [Sessions] INTO '" & sPath & "delme.gif'
FROM '" & sPath & "WMS_ISAPI_20040826.log' GROUP BY [c-ip]"

Dim lg1 As New MSUtil.LogQueryClass
lg1.ExecuteBatch(query, inputContext, outputContext) '<-- Error occurs here

Apr 20 '07 #2
gabriel gussipini can provide the exact syntax. he authored the logparser
utility. Unfortunately he is no longer at MS. But you can track him down via
email be replying to the log parser book support email. Hope that helps.

--
Regards,
Alvin Bruney
------------------------------------------------------
Shameless author plug
Excel Services for .NET is coming...
OWC Black book on Amazon and
www.lulu.com/owc
Professional VSTO 2005 - Wrox/Wiley
"Mike Lowery" <se******@mouse-potato.comwrote in message
news:O8**************@TK2MSFTNGP02.phx.gbl...
Did a little more playing around. Turns out if I specify the destination
as something like c:\temp\delme.gif it works, but if there are any spaces
in the file path it fails (c:\temp temp\delme.gif). Strange thing is that
spaces in the path doesn't affect the reading of the log file!

So now the question is how to get this to work with spaces in the path...
already tried enclosing it in quotations (same result.)

"Mike Lowery" <se******@mouse-potato.comwrote in message
news:OC**************@TK2MSFTNGP03.phx.gbl...
>I'm trying to write an ASP.Net app that uses Log Parser 2.2's COM
interface to read some Windows Media Server (W3C) log files and generate
a chart (GIF file) on the web server. I'm getting an error when
attempting to generate the chart using the ExecuteBatch method:

Error executing query: Unexpected internal error calling chart object
method ExportPicture: Exception occurred. [Exception occurred.]

Office 2003 Web Components is installed and other output types (XML) work
just fine. So I'm guessing this is a permissions or registration error
w/OWC, but not sure. Hoping someone can point me in the right direction.

Here's the ASP.Net code:

Dim sPath As String = Request.PhysicalApplicationPath
Dim inputContext As New MSUtil.COMW3CInputContextClass
Dim outputContext As New MSUtil.COMChartOutputContextClass

outputContext.chartType = "BarClustered"

Dim query As String
query = "SELECT [c-ip], COUNT(*) AS [Sessions] INTO '" & sPath &
"delme.gif' FROM '" & sPath & "WMS_ISAPI_20040826.log' GROUP BY [c-ip]"

Dim lg1 As New MSUtil.LogQueryClass
lg1.ExecuteBatch(query, inputContext, outputContext) '<-- Error occurs
here


Apr 22 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2710
by: Himanshu Garg | last post by:
Hello, I am using HTML::Parser to extract text from html pages from http://bbc.co.uk/urdu/ However the encoding of the input text seems to change to some unknown encoding in the output. The...
4
3076
by: billcoumbe | last post by:
any recommendations? I'm looking for something that will just run from the unix command line to validate large (20-50Mb) XML files against an XML DTD. Ideally something that is actively...
1
3811
by: Scott H. | last post by:
Hello: I am trying to use Crystal Reports from VS.NET 2003 to produce a simple line chart, where the x axis represents the number of measurements taken and the y axis represents the range of...
4
1695
by: M Arora | last post by:
Hi All I am using Xerces parser to convert my xml to the output given below and for this i am using the xslt. How shall i create href attribute in xerces parser? When i am using MSDOM parser...
5
10413
by: Kuna | last post by:
Hi All, I am trying to create a gantt chart in php by getting data from database. I am using WindowsXp OS and having php-4 and my-sql DB. I have installed the JPGRAPH package to my system and...
1
1618
by: =?Utf-8?B?U00=?= | last post by:
Hi, We have developed an application that transforms xsl into excel file and present xsl file to the user with data. We use open xml features of excel 2003. Our user is now asking for a chart to...
28
16350
by: Marc Gravell | last post by:
In Linq, you can apparently get a meaningful body from and expression's .ToString(); random question - does anybody know if linq also includes a parser? It just seemed it might be a handy way to...
5
5711
by: grant | last post by:
I'm trying to use a scatter chart to plot level reading for a pump station level sensor. The sensor takes a reading every 4 seconds, and there are 23,000 reading per chart There appears to be...
3
3814
by: ups_genius | last post by:
Hi everyone! I created an error parser using the existing CDT stuff by basically copying some of the GNU / make / ... error parsers' code. I also added the extension point for the new error...
0
7202
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7278
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7328
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5578
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5013
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4672
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3167
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3154
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
736
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.