H
HG
Hi gurus
Sorry the rather long post...
I am facing a real world problem here, and I dunno how to approach it.
Don't even know if this is the right group...but since my app is ASP.NET I
tried here first.
I have an ASP.NET WebApp running, database tier is SQL Server 2000 in a
intranet environment.
The front end is HTML (generated from ASP.NET pages). Nothing new here.
BUT:
I want to add letter writing and reporting facilities based on the data in
SQL Server.
The lette writing has to be done in Word and the reporting in Excel. So I
though of the following scenario:
- Have a template (.dot for Word), which is hosted on the Web Server. When
the user hits the link to the template my ASP.NET page will put some
parameters in the session, before it return the requested template as
content to the browser. In the document template a VBA OnLoad eventhandler
has been implemented. What it will do, comes later.
- When the template is received at the browser, it show a new document based
on this template AND the code in the VBA OnLoad eventhandler is executed.
- The VBA code, contacts a WebService hosted on the very same webserver that
the template was received from. The WebService fetches the parameters that
were placed on the session before returned the document template, and
executes a query against the database. The result of the quuery is returned
as XML to the client (ie. still the OnLoad eventhandler)
- The VBA code, parses the XML and performs inserts at the correct places in
the new document.
- Done.!
Serveral issue arise here:
1)
Does the template show up as a new document based on that template?
2)
Does security setttings allow the OnLoad eventhandler to be executed?
3)
Does WebService call share the same session as the browser? Is it possible
to get to the parameters that the ASP.NET page placed there?
These 3 issues a crucial for the above to work.
Are there any other way... What about the WebServices ToolKit for Office XP?
Anyone please
Sorry the rather long post...
I am facing a real world problem here, and I dunno how to approach it.
Don't even know if this is the right group...but since my app is ASP.NET I
tried here first.
I have an ASP.NET WebApp running, database tier is SQL Server 2000 in a
intranet environment.
The front end is HTML (generated from ASP.NET pages). Nothing new here.
BUT:
I want to add letter writing and reporting facilities based on the data in
SQL Server.
The lette writing has to be done in Word and the reporting in Excel. So I
though of the following scenario:
- Have a template (.dot for Word), which is hosted on the Web Server. When
the user hits the link to the template my ASP.NET page will put some
parameters in the session, before it return the requested template as
content to the browser. In the document template a VBA OnLoad eventhandler
has been implemented. What it will do, comes later.
- When the template is received at the browser, it show a new document based
on this template AND the code in the VBA OnLoad eventhandler is executed.
- The VBA code, contacts a WebService hosted on the very same webserver that
the template was received from. The WebService fetches the parameters that
were placed on the session before returned the document template, and
executes a query against the database. The result of the quuery is returned
as XML to the client (ie. still the OnLoad eventhandler)
- The VBA code, parses the XML and performs inserts at the correct places in
the new document.
- Done.!
Serveral issue arise here:
1)
Does the template show up as a new document based on that template?
2)
Does security setttings allow the OnLoad eventhandler to be executed?
3)
Does WebService call share the same session as the browser? Is it possible
to get to the parameters that the ASP.NET page placed there?
These 3 issues a crucial for the above to work.
Are there any other way... What about the WebServices ToolKit for Office XP?
Anyone please