Re: how can you use mshtml DOM object to grab rendered asp.net page?
- From: "Randall Arnold" <rgarnold@xxxxxxxxxxxxxx>
- Date: Mon, 2 Jan 2006 00:28:58 -0600
I am very new to asp.net/vb.net (although over 10 years with vb), and what
you describe is utterly foreign to me. If I knew what all that was, trust
me: I'd probably have done it.
Looks like I have a lot more to learn... and based on the poor luck I'm
having in searches, I don't even know where to start. No books, it seems,
geared toward what I am trying to do.
And FYI, it was never my intention to design myself into a corner: I had a
mandate to modernize a VB6 app and provide it with various publishing
(export) options, assumed asp.net was the way to go, and have now come to
the conclusion asp.net is far too immature, restrictive and poorly supported
despite the hype from Microsoft. IMO, I should not have to jump through
hoops or worry about security restrictions when my environment is 100%
intranet.
Randall
"Robbe Morris [C# MVP]" <info@xxxxxxxxxxxxxxx> wrote in message
news:%23k6TbFVDGHA.3064@xxxxxxxxxxxxxxxxxxxxxxx
> Is there a reason you don't have set aside classes with public methods
> to generate your charts, html tables, and other output mechanisms?
>
> You could then wire up a few .NET Web Services to call these
> specific methods from other parts of your web application or
> even in VBA in Office applications.
>
> It appears that you've put a bunch of this logic in your code
> behind files. While this doesn't prohibit you from parsing
> out particular pieces of info from the page, it does make
> it more problematic.
>
> You should refactor your asp.net pages and put the methods
> to draw your html tables, charts, etc. in separate classes and
> perhaps even in their own assembly.
>
> This way, you can call the methods via web services and not have to bother
> parsing anything. And, it would be easy to use the XmlHttp
> object from the MSXML4 (or whatever the latest version is)
> to call your web service via a macro in office. Now, you can call
> the same method easily from external applications as well
> as your asp.net application.
>
> I think you've just architected yourself into a bad corner knowing
> that you want to share output from your asp.net app to other
> applications. You may want to review the following.
> It will help you avoid these types of things in the future.
>
> http://www.eggheadcafe.com/articles/aspnet_how_to_create_object_oriented_applications.asp
>
> --
> Robbe Morris - 2004/2005 Microsoft MVP C#
> http://www.eggheadcafe.com/forums/merit.asp
>
>
>
>
>
> "Randall Arnold" <rgarnold@xxxxxxxxxxxxxx> wrote in message
> news:eLjrtEQDGHA.628@xxxxxxxxxxxxxxxxxxxxxxx
>> Ok, I can understand that, but with all due respect I still can't accept
>> that I can't achieve this one way or another. Again, I have no problem
>> copying the chart graphic to the clipboard and bringing it into
>> PowerPoint with 2 simple lines of code, and it looks beautiful. I have
>> to believe that there is *some* way of copying a simple table over as
>> well, without going through contortions. I keep seeing hints that it can
>> be done but either the methods don't work for me or there aren't enough
>> details provided. Someone told me there's a way to stream the table to
>> PowerPoint but provided no other info. ???
>>
>> Right now the 2 options I know I can use are the cumbersome html file
>> generation technique and building each and every table from scratch in
>> PowerPoint using vba with the interop. I have issues with either
>> approach, but I'll use the former if I have no other choice. MUCH less
>> code.
>>
>> The thing that gets me is I found an asp.net/JavaScript combo trick that
>> allows the user to toggle a table between hidden and visible. I got this
>> to work on the page in question. If I can do THAT, I have to believe I
>> can use a similar trick to copy the table. I just need to know the
>> method.
>>
>> Randall Arnold
>>
>> "Jim Cheshire" <noemail@xxxxxxxx> wrote in message
>> news:eOc2aHODGHA.3748@xxxxxxxxxxxxxxxxxxxxxxx
>>> Randall Arnold wrote:
>>>> I can't understand why I can't simply programmatically
>>>> access the rendered html table, especially since I can highlight it
>>>> with a mouse, copy, paste and done. I should be able to emulate that
>>>> action in vb.net code, right? If I can't *I* have serious
>>>> reservations about the maturity level of asp.net.
>>>> Randall
>>>>
>>>
>>> I went back and read your original post. It seems that you want to copy
>>> this to the client clipboard. Is that correct? If so, can't be done in
>>> ASP.NET. ASP.NET code doesn't execute on the client.
>>>
>>> --
>>> Jim Cheshire
>>> ================================
>>> Blog: http://blogs.msdn.com/jamesche
>>>
>>> Latest entry: Digging into Objects
>>> Describes the details of digging into
>>> memory usage with the debugger.
>>>
>>>
>>>
>>
>>
>
>
.
- Follow-Ups:
- Re: how can you use mshtml DOM object to grab rendered asp.net page?
- From: Jim Cheshire
- Re: how can you use mshtml DOM object to grab rendered asp.net page?
- Prev by Date: Re: how can you use mshtml DOM object to grab rendered asp.net page?
- Next by Date: Namespace Problem
- Previous by thread: Re: how can you use mshtml DOM object to grab rendered asp.net page?
- Next by thread: Re: how can you use mshtml DOM object to grab rendered asp.net page?
- Index(es):
Relevant Pages
|