IE COM object within web service

ASP.NET

    Next

  • 1. Problem to access SOAP Header
    I would like to know how to access the SOAP header data?. I'm building an Infopath Application using JScript that will consume a C#-implemented webservice. The Infopath Application already generated the following SOAP message,
  • 2. ASPX control issue
    Hello, Here it goes, our web developer developed our web site using Dreamweaver and now I'm using VS .NET to redirect the pages to use the web services I created. She created a template which every page used to display hover buttons, drop down menus ..... in this template I created a label which will displays a money odometer that connects to a web service every second to display the progressing amount. This works, the issue is when I open up a .aspx page using this template, I loose the focus on the .aspx page using the template. I click in a textbox field on the .aspx page the cursor blinks once and looses focus. Here's the kicker, if I use the "tab" button the focus stays in the textbox fields and allows the user to type. Is the page repainting due to the amount changing in the template which the .aspx page is using? The page does not flash or reload, so I'm lost. Any help would be apprectiated. Thank you, Terry
  • 3. Index was outside the bounds of the array
    Hi there, We have a web application written in asp.net (1.1). I'm not going to go into too much detail but we use a DLL to communicate with the database and also a couple of webservices. When we deployed version 1, everything deployed OK on our webserver. We deployed the application and 1 webservice under default web site, the other webservice (3rd party supplied) is on another server and services many other application in our organisation sucessfully. Recently we have tried to deploy version 2, but this time we have assigned another IP address to the web server and tried to install the application under a new website. Everything looked OK the application installed OK and most of the functionallity works just fine but 1 or 2 of the webservice calls fails with the error: "Index was outside the bounds of the array" I get this error on both webservices, on specific webmethods, but it DOES work OK on default website.... Any help on this would be appreciated Cammie
  • 4. Webservices with raw post data
    Hello, I'm working on migrating a webservice my company currently has written in PHP over to a .Net webservice. Our service works like this: Applications makes a HTTP POST request to the webservice with the raw post data consisting of XML. The XML service creates the request processing object, passing the raw XML Once the service is done, it returns the response XML on the same connection. This webservice does not use SOAP at all, it uses a custom request and response schema deffined by us. My question is, how do I get access to the raw post data in an 'offical' XML web service? Or can I even? As far as I can see right now it seems that SOAP was basically made a requirement for webservices in ASP.Net, and I can't find any documentation telling me how to get access to raw post data in an XML web service. Can this be done? Or do I need to create an ASP.Net website which consits of a single webpage wich happend to accept only raw posted XML and happens to return only the XML response? Any help would be appriciated. Thanks, Carlo Razzeto

IE COM object within web service

Postby shonend » Fri, 09 Jul 2004 01:15:26 GMT

Hi,
can you please help me figure out what I need to do to make IE COM
object (namely, using IEBrowser =
CreateObject("InternetExplorer.Application")) work within the web
service?
I manage to pass the "cannot create COM object" error, by setting the
IE security properties in "dcomcfg.exe", but it seems that IE can't
perform form submit operation on the containing webpage. More
precisely, the IE object is successfuly created, navigates to the
homepage, I supply the values to the form fields, but when I try to
submit the form, it just hangs there forever or times-out eventually.
No need to mention that all this works fine when run from the windows
form app.

Thanks much...
Shone

Re: IE COM object within web service

Postby Girish Bharadwaj » Sat, 10 Jul 2004 00:44:46 GMT

Umm. You might want to look into to some objects from .NET natively such  
as HttpWebRequest.
Using IE to do what you are doing, seems a bit extreme.







-- 
Girish Bharadwaj

Re: IE COM object within web service

Postby shonend » Sat, 10 Jul 2004 23:11:23 GMT

oh, no, no, no... can't do it!
You see, I'm developing a "robot" to replace the human in tedious and
repetitive tasks of surfing the website and gathering info. Imagine
the user having to go back and forth, click here and there, supply the
same criteria several times and have all his/her data just shown on
the screen, so it needs to be written down or copy/pasted. It would
take him/her at least half an hour for aeach case. Not so bad? Well,
how about 50-60 such cases he/she needs to do a day? My program will
replace all this by having to supply the criteria only once and click
a button, so the request goes into the queue and being processed in a
batch.
So it's complex enough to program the human thinking and decision
logic, I can't also re-program complex IE functionality. It would be
too much to have to generate GET/POST request, support the cookies,
extract the href from the inner HTML tags and forms... etc., when IE
object already does all that behind the scene. All I need is to
recognize the elements on a given page , supply the data into fields
and programatically "click" the links and clickable tags, "submit" the
forms , go back and forth, etc, and finally read the results. And this
is complex enough believe me.
I would rather use the native .NET classes, but there are no such yet
(somebody said on the forum that those are expected in ver. 2
framework), so I had to use COM (Shdocwv.InternetExplorer).

So what do you think about this strange behavior? To remind you, IE
appears to be working fine under WS, untill I try to submit a form or
click a link that has "submit" role on a form. As long as I just do
navigation to URL, setting the field values or clicking a "simple"
links to other pages - it works OK.
Example:
   objIE.Navigate("http:/someURL") - WORKS
   objIE.Document.all("ctlName").value="somevalue" - WORKS
   objIE.Document.all("tagName").click - WORKS, if a tag is not a
submit type on a form

   objIE.Document.all("formName").Submit() - DOESN'T WORK


thanks for your interest,
greetings...







Similar Threads:

1.Using a COM object from within a Windows Service

From within a Windows Service how can I determine my current ProcessID or 
ProcessName.  I'm creating a COM object and want to return focus back to my 
original process to allow the application to register in the (ROT - not sure 
what it stands for anyway but that's how it works in a WinForm).  
Subsequently, the code looks for a running instance of the COM object using 
the GetObject command.  

From a Windows Form, the command in question is 

AppActivate(title:=me.title)

In a service, you don't have a form so what would you use instead.

Thus I'm looking for...

Function GetApplication(parms) as object
MyProcess = something
dim oAccess as "Access.Application"

create / open a new comobject (e.g. Microsoft Access in Hidden mode) ...

' Return to Main Process to allow it to Register in ROT
AppActivate(myprocess)  <=== 

' Wait a few seconds and then get the object
oAccess = Getobject(database I opened earlier)
Return oAccess

end function

In this instance, I am attempting to load an instance of Microsoft Access, 
run a report to disk from within a Windows Service.  Given that a service can 
have no user interface am I destined for failure?  If so, what is my best 
alternative to accomplish this task.  I want this action to happen on a 
schedule without requiring a user to login (thus I'm trying to use a 
service).  I've got it (report generator) working from within a regular .net 
WinForm application and simply want it to be triggered by the service.

Any ideas / suggestions would be much appreciated.


Thanks,


2.initialize COM within a web service

I'm currently trying to use API's in Microsoft Virtual Server 2005. I can 
initialize COM just fine from anything other then a web service whihc is were 
i would like to make available the methods that will do the virtual server 
work i need.

I have tryed to initialize COM from everywhere in the web service and i 
always get the same message that states that you have to initialize COm 
before doign anything or marshaling ect...

I'm starting to think that this cant be done but i'm new to all this so that 
could explain alot.

Thanks for any help

3.COM+ Web Services (ie remoting com+ from IIS)

Whilst I await a response for the problem I have getting this working for me 
I would like to ask another question related to enabling COM+ components to 
be called as web services (checking the SOAP checkbox on the activation tab 
of the com+ application properties).

Are there any performance issues with this method, instead of wrapping up 
the classes and exposing webmethods yourself?  If so what can be done to 
minimise these?

All com+ applications in this scenario are c# (managed code).



--------------------------
Shaun Venus

emailid:  sunevnuahs
domain:  hotmail.com
--------------------------

4.Referencing web service complex data type within a second web service (like a delegate)

Hi,
   I am trying to figure out if ASP.NET XML Web Services and the WSDL
standard can handle this type of scenario:

I have two web services, and one consumer client application.  Lets
call web service 1 "basews", and web service 2 "custom", and the
client app "client".

I want basews to define a delegate of sorts (where the delegate
signature contains complex data types as arguments and return types),
and then custom ws would conform to the basews delegate signatures, so
that within client, I can call them similar to how delegates actually
work in .NET (with the obvious overhead of SOAP, etc).


If basews has the following pseudo-structure (VB'ish) :

-----------------
Class basews
<WebMethod()> Public Function getComplexDataType(byval req as
MyRequest) as MyDataType
   ...
End Class

Public Class MyDataType
   Public field as String
   ...
End Class

Public class MyRequest
   Public field as Integer
   ...
End Class
-----------------

where MyDataType and MyRequest (really can be more complex) are added
to basews WSDL automatically by .NET.


Can I create "custom" ws like this:

-----------------
Class custom
<WebMethod()> Public Function customGetComplexDataType(byval req as
basews.MyRequest) as basews.MyDataType
   ...
End Class
-----------------


such that within "client", it treats the return type of both web
service's methods as the same type?  Or if this is not possible, is
there a way of at least being able to treat
basews.MyDataType/MyRequest and custom.MyDataType/MyRequest the same
so that I only have to write one routine to populate/read MyDataType
and MyRequest within "client"?

This is going to be used with dynamic web service binding techniques
so that I can take an arbitrary WSDL and method names that conform to
certain signatures (like delegates) and be able to call them
appropriately.

Thanks for the replies.  Also, if you could copy me at 'mdearman
NOSPAM at libera.com' I would be grateful so I don't accidently miss
any replies.

5.calling a web service from within a web service

hi

i'm looking for some heads up info regarding calling and using a web service 
from within another web service. is this acceptable practice? if not why? 
what should i be thinking about here?

cheers 


6. Using an object pool within a web service

7. DataGridView object within a collection from web services

8. Problem with Web Service and COM Object



Return to ASP.NET

 

Who is online

Users browsing this forum: No registered users and 83 guest