|
Actually, that's not even possible. XML Web Services are invoked over HTTP, which is - by nature (and it's very protocol) - client request / server response driven. A server cannot contact a client; only a client can make requests on the server, in which case the server (should) respond.
If you need a "net send" equivalent take a look at the .NET Remoting Overview[^]. You'll want to use a channel that is not HTTP-based, like the TcpChannel . The clients will still need to connect to the server (like a chat application), but they can stay connected and the .remoted object (on the remoting server) can send the connected clients data or even invoke requests on the client, instead of only the clients being able to invoke methods on the server.
The .NET Framework 1.x provides the HttpChannel and TcpChannel , and 2.0 will add an IpcChannel . Channels - like formatters - are extensible. Here on CodeProject someone even posted a channel using MSMQ (Microsoft Message Queue) server. Nifty.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Hello All,
I want to send fax from a c#.Net form using rightfax.dll(version 8.5.0.103), can anyone pls provide me a insight of this by providing a piece of code or any article for the same.
your advice would be highly appreciated.
This is very urgent.
Regards
Pavan
|
|
|
|
|
RighFax is a third-party library/application and you need to read any developer documentation they have, like at http://www.captaris.com/customer_support/tech_docs/5609.html[^]. This forum is not about supporting third-party libraries, but questions specific to C#.
Your question is how to interop with it. For that, you can read about in Consuming Unmanaged DLL Functions[^] and Marshaling Data with Platform Invoke[^] in the .NET Framework SDK. If you have questions beyond what you should read you could ask here.
As far as what native APIs to P/Invoke, and what data structurs, constants, and interfaces to declare in C# is beyond the scope of this forum. You would only be able to determine that information by reading the developer documentation for RightFax or finding a developer community specific for RightFax, if such a community exists.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Hi,
http://www.captaris.com/customer_support/tech_docs/5609.html
The above link is not working.Can some one post a sample code to send a fax using RightFax.
Thanks.
Kotte
|
|
|
|
|
I want to develop a web server. When a user says from the browser http://localhost:8080 server must return a web page with text box and browser button and upload button. User can select the file and can click the button Upload. Let us say webserver.exe is present in c:\. When user clicks upload button this must be handled by the webserver and should upload the file to the same drive where the web server is running. I mean in C:\. In this case a POST method has to be handled. I am unable to handle the post method in my scenario. This will be regarding Content-Length,content-type processing.
Can any one help me in this regard by specifying sample code. I am already running out of submission date.
|
|
|
|
|
Developing a web server in C# probably wouldn't be the most efficient language to use, however if this is something you want to attempt, you should take a look at the System.Net[^] namespace, specifically the Socket[^] class.
- Nick Parker My Blog | My Articles
|
|
|
|
|
If you want to host an ASP.NET web application without IIS, you can use the hosting interfaces. See the System.Web.Hosting[^] namespace in the .NET Framework SDK. Read ASP. NET Client-side Hosting with Cassini[^] in MSDN Magazine for an example of using the ApplicationHost class.
There's also several articles about building a web server (HTTP daemon) here on CodeProject, like Create your own Web Server using C#[^] by Imtiaz Alam. You can search for additional articles using the site search feature.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
This will probably remain unanswered, but does anyone know of a method of finding out whether a pocket PC (ipaq) is attached to the desktop via the usb port? I've looked briefly at WMI using:
select * from Win32_USBHub
and System.Management.ObjectQuery, but couldn't find any clues. My other guess is that I use SendMessage with the ActiveSync exe, but this will be fidley.
Thanks
|
|
|
|
|
smallguy78 wrote:
This will probably remain unanswered
That's a rather negative way to start off a question. Fortunately some of us like research.
There are several ways documented in the ActiveSync APIs, from getting notified of connection to querying for a device ID, which I've coded below:
using System;
using System.Runtime.InteropServices;
class DetectDevice
{
static void Main()
{
int id = CeGetDeviceId();
if (id == 0)
Console.WriteLine("Device not connected.");
else if (id == -1)
Console.WriteLine("Quest device connected.");
else
Console.WriteLine("Device ID: " + id);
}
[DllImport("ceutil.dll")]
static extern int CeGetDeviceId();
} Unfortunately I'm not able to test this, but it should work. This morning I decided to leave my iPAQ at home thinking I wouldn't need it, but figuring that if I didn't take it I'd probably need it. I guess I did.
Let me know if this works, though. There are a number of other ways, but this way seems to be the easiest.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Heath Stewart wrote:
Fortunately some of us like research
You can say that again.
- Nick Parker My Blog | My Articles
|
|
|
|
|
Hi all,
Iam developing an pocket pc application in .NET Compact framework and run it the emulator. I dont know where the EXE and other application files are stored in that emulator.
Sridhar.
|
|
|
|
|
Hi all,
Iam developing an pocket pc application in .NET Compact framework and run it the emulator. I dont know where the EXE and other application files are stored in that emulator.
Sridhar.
|
|
|
|
|
The application is loaded into memory, along with dependent assemblies from dependent projects. To actually install the application and related content files you need to create a deployment project, then deploy into the emulator.
For more information about developing Smart Device Application and deployment projects for said projects, read Developing Smart Device Applications[^] in the MSDN Library.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
hi,
Thanks for your kind reply, I have some more doubts in this regards could u suggest me any tutorial and other books in internet. It is possible to trace TAB Key in Compact Framework and also can i create my own components like numeric textbox, alpha textbox etc.....
Thanks and regards,
Sridhar.
Sridhar.
|
|
|
|
|
hi,
Thanks for your kind reply and say it is possible to manually copy a file from PC to Emulator.
Thanks
Sridhar.
sdaf
|
|
|
|
|
Follow the link I gave you. Under that is a topic that clearly describes how to do what you want.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
hi,
Thanks for your kind reply, I have some more doubts in this regards could u suggest me any tutorial and other books in internet. It is possible to trace TAB Key in Compact Framework and also can i create my own components like numeric textbox, alpha textbox etc.....
Thanks and regards,
Sridhar.
Sridhar.
sdaf
|
|
|
|
|
If by "trace" you mean capture, then yes you can capture the [Tab] key being pressed. Handle the KeyDown event (or, in a derived control, override OnKeyDown , being sure to call at some point base.OnKeyDown ) and check the KeyEventArgs.KeyCode for Keys.Tab .
You can extend controls to create your own, or create a UserControl derivative to contain multiple controls (what's called a container control). There's really not much you can't do.
If you're new to programming, I suggest browsing the relevent articles here on this site and checking out books about .NET at http://www.microsoft.com/mspress[^].
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
hi,
once again Than Q, Happy New Year, Please could you give the sample code to capture the Keys and for User controls.
Please mail to k.sridhar@solutionnet.net
Thanking you,
Sridhar.
Sridhar
|
|
|
|
|
hello
i am calcualting factorial and saving its value in double data type. But double can't calculate factorial of >170 .
Plz help me if u know how can i calculate factorial of above 200 or say 500 factorial.
Regards
asmyan
|
|
|
|
|
The following appears to work for me:
private double factorial(double f)
{
double num = Math.Floor(f);
if(num < 0)
{
return -1;
}
if(num == 0)
{
return 1;
}
else
{
return (num * factorial(num - 1));
}
}
- Nick Parker My Blog | My Articles
|
|
|
|
|
hello
Thank you so much for such a quick prompt. All of you are so nice and helping people.
Regards
asmyan
|
|
|
|
|
hi
you must use arraylist;
do this:
you must define the multiplication yourself on the arraylist.
each elements of arraylist contains only one integer.
say
for( int i=1;i< 500;i++)
{
multiplay i in each elemnt of arrayList and add its more than 10 of element to next element such you do on paper.
}
you can calculate n! by this
|
|
|
|
|
hello
i am calcualting factorial and saving its value in double data type. But double can't calculate factorial of >170 .
Plz help me if u know how can i calculate factorial of above 200 or say 500 factorial.
Regards
aneela
|
|
|
|
|