|
-
May 8th, 2013, 10:45 PM
#1
Thread Starter
Fanatic Member
[RESOLVED] Idea's regarding a parent app with added modules/mini apps
Hi
I find myself rewriting these small apps for people all the time which do very basic things, usually rearranging files, merging, parsing etc, so im trying to come
up with an application where i can incorporate everything into 1 application,
the idea is....
1. have a parent application with simple ui which will 'host' the other functions/mini-apps
2. be able to add/remove functionality by simply adding/.removing a 'File' into a directory which the parent application will check for
3. have any found files listed in a toolbox/ribbon on a button which you click and using the information on the parent will kick into action
my initial idea 'for practice purposes' was, having the mini-app as console apps and winform apps and launching them from the parent and maybe pass arguments or have a global class available for them to get the information they need. which leads to question 1
Question 1....
assuming i have 2 projects open each with a form with a button and a label, how do i make them communicate to eachother by......
pressing the button on app1 form GIVES the text in the label to the other apps form
and
pressing the button on the app2 form REQUESTS what is on the label of the other form.
so simply put, SEND and REQUEST between applications
Question 2....
going back to my parent child app idea, should i be making dll's not mini-apps?
if so, how do i add 'random' dll's to an already compiled program (extensions)
thanks
Yes!!!
Working from home is so much better than working in an office...
Nothing can beat the combined stress of getting your work done on time whilst
1. one toddler keeps pressing your AVR's power button
2. one baby keeps crying for milk
3. one child keeps running in and out of the house screaming and shouting
4. one wife keeps nagging you to stop playing on the pc and do some real work.. house chores
5. working at 1 O'clock in the morning because nobody is awake at that time
6. being grossly underpaid for all your hard work

-
May 8th, 2013, 11:40 PM
#2
Re: Idea's regarding a parent app with added modules/mini apps
1. What you're talking about is inter-process communication (IPC) and that is a widely discussed topic so you can find lots of information on it. There are various ways it can be done but one fairly simple way in .NET is via TCP using the TcpListener and TcpClient classes. Just note that TCP communication can run afoul of a firewall.
2. You can't really add a random DLL to an app because the code to be able to interrogate an unknown DLL and use it's functionality would be very hard to write. The DLLs really need to be written specifically to work with your app. Such a component is usually referred to as an add-in or a plug-in. Again, this is a very widely discussed topic. There is plenty of functionality in the .NET Framework to support this and it's usually done in one of three ways. The most recent and most flexible approach is to the the Managed Extensibility Framework (MEF). The "old" way is to simply design your own interface for each plug-in to implement. If you search the web for .net plugin architecture then you'll likely find several results using that "old" option.
-
May 8th, 2013, 11:53 PM
#3
Thread Starter
Fanatic Member
Re: Idea's regarding a parent app with added modules/mini apps
Hi,
thanks i think you hit everything on the head there, ill look into those
regarding (IPC) im not after communication over the internet just yet, although i will also go over that, it looks interesting. im just interested in how i can get 2 programs talking to each other
am i right in saying if i used ip 127.0.0.1 with the tcplistener/Client classes etc, i would in effect achieve 2 programs communicating on the same pc, and it would be good practice for if i did want internet communication can i hit 2 birds with 1 stone there.
i will look into (MEF) right now so i can get started
thanks
Yes!!!
Working from home is so much better than working in an office...
Nothing can beat the combined stress of getting your work done on time whilst
1. one toddler keeps pressing your AVR's power button
2. one baby keeps crying for milk
3. one child keeps running in and out of the house screaming and shouting
4. one wife keeps nagging you to stop playing on the pc and do some real work.. house chores
5. working at 1 O'clock in the morning because nobody is awake at that time
6. being grossly underpaid for all your hard work

-
May 9th, 2013, 12:01 AM
#4
Re: Idea's regarding a parent app with added modules/mini apps
 Originally Posted by GBeats
am i right in saying if i used ip 127.0.0.1 with the tcplistener/Client classes etc, i would in effect achieve 2 programs communicating on the same pc, and it would be good practice for if i did want internet communication  can i hit 2 birds with 1 stone there.
Correct. TCP communication is the same whether on the same machine, the same local network or over the internet.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|