0

I have a winform application that controls some transmitters and sound cards. There is a requirement to be able to provide a web interface for controlling those devices.

Currently I use WCF to communicate from the controllers in my asp.net MVC site to the winform app. That works well, but there is now a desire to move the hardware to another machine when needed and that means that IIS has to be installed and set-up on that machine.

I know it isn't that hard, but I won't be the one actually doing the moving. It will be the users. If I could host the site from the winform app them it would basically be portable besides the hardware drivers need for a usb to serial converter we use.

4 Answers 4

1

Can you use a windows service? The whole winforms app as a service doesn't seem right to me. It assumes that the app is always running. I would create a windows service and expose WCF endpoints from that.

Sign up to request clarification or add additional context in comments.

1 Comment

That is the end goal, but we haven't gotten it feature complete enough. The winform app lets me test it really quickly from my machine. I have a set of the hardware hooked up locally. Thanks for the answer.
1

You will need to install IIS or Cassini to host the MVC web site. There's no way around that.

Comments

1

Huh, I would go with Greg's answers.

Also, making your app IIS dependant is not that bad. Or Cassini dependant. You don't want to end up writing your own webserver, which could easily happen when you continue to add features to the app.

I don't know about you but it just feels you are taking all the load on yourself, you are going to spend possibly dozens of hours to implement it to spare an hour or two for someone who doesn't want to install real webserver.

1 Comment

Yeah, figured as much, just trying to deal with my customers. They want to be able to do everything without needing help from the technical staff.
0

if you want to host MVC under winforms then i would look into the upcoming .netcore 3 version which should allow this combination.

though you'll have to wait until 2019 Q1 https://github.com/dotnet/core/blob/master/roadmap.md

otherwise i've mostly hosted simper stuff using nhttp library if i want it in a winform app.

(NHTTP is a library that gives you very simple crude http request functionality so no mvc sadly but it works for simnpler stuff)

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.