473,503 Members | 3,171 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Send to VB.NET program?

I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben
Nov 21 '05 #1
6 2369
On Tue, 26 Oct 2004 15:16:41 -0500, Becker wrote:
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben


When a file is "sent to" your application, your application is just started
with the name of the file passed into the command line. The only thing you
need to do is to check the command line when the app is started for the
name of the file to process. The other step is to add a shortcut to your
app to the Send To folder of the user in question.

--
Chris

dunawayc[AT]sbcglobal_lunchmeat_[DOT]net

To send me an E-mail, remove the "[", "]", underscores ,lunchmeat, and
replace certain words in my E-Mail address.
Nov 21 '05 #2
On Tue, 26 Oct 2004 15:16:41 -0500, Becker wrote:
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben


When a file is "sent to" your application, your application is just started
with the name of the file passed into the command line. The only thing you
need to do is to check the command line when the app is started for the
name of the file to process. The other step is to add a shortcut to your
app to the Send To folder of the user in question.

--
Chris

dunawayc[AT]sbcglobal_lunchmeat_[DOT]net

To send me an E-mail, remove the "[", "]", underscores ,lunchmeat, and
replace certain words in my E-Mail address.
Nov 21 '05 #3
Chris,

That is what I'm not sure how to do. Do I do that on the form load event?
and if so, what class am I checking?

Thanks,
Ben

"Chris Dunaway" <"dunawayc[[at]_lunchmeat_sbcglobal[dot]]net"> wrote in
message news:1t******************************@40tude.net.. .
On Tue, 26 Oct 2004 15:16:41 -0500, Becker wrote:
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben


When a file is "sent to" your application, your application is just
started
with the name of the file passed into the command line. The only thing
you
need to do is to check the command line when the app is started for the
name of the file to process. The other step is to add a shortcut to your
app to the Send To folder of the user in question.

--
Chris

dunawayc[AT]sbcglobal_lunchmeat_[DOT]net

To send me an E-mail, remove the "[", "]", underscores ,lunchmeat, and
replace certain words in my E-Mail address.

Nov 21 '05 #4
Chris,

That is what I'm not sure how to do. Do I do that on the form load event?
and if so, what class am I checking?

Thanks,
Ben

"Chris Dunaway" <"dunawayc[[at]_lunchmeat_sbcglobal[dot]]net"> wrote in
message news:1t******************************@40tude.net.. .
On Tue, 26 Oct 2004 15:16:41 -0500, Becker wrote:
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben


When a file is "sent to" your application, your application is just
started
with the name of the file passed into the command line. The only thing
you
need to do is to check the command line when the app is started for the
name of the file to process. The other step is to add a shortcut to your
app to the Send To folder of the user in question.

--
Chris

dunawayc[AT]sbcglobal_lunchmeat_[DOT]net

To send me an E-mail, remove the "[", "]", underscores ,lunchmeat, and
replace certain words in my E-Mail address.

Nov 21 '05 #5
VJ
you should check the arguments in the SubMain function... Then call your
program.. See below for a template..This should work...

Private strArg1 As String

Public Sub Main(ByVal agrs1 As String)
Application.Run(New Form1(agrs1))
End Sub
#Region " Windows Form Designer generated code "

Public Sub New(ByVal arg1 As String)
MyBase.New()

'This call is required by the Windows Form Designer.
InitializeComponent()

'Add any initialization after the InitializeComponent() call

End Sub

#end region
Private Sub Button1_Click(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Button1.Click

MsgBox(strArg1)

End Sub

VJ
(please do check for syntax and typos!!)

"Becker" <be*@benbecker.net> wrote in message
news:up*************@TK2MSFTNGP15.phx.gbl...
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben

Nov 21 '05 #6
VJ
you should check the arguments in the SubMain function... Then call your
program.. See below for a template..This should work...

Private strArg1 As String

Public Sub Main(ByVal agrs1 As String)
Application.Run(New Form1(agrs1))
End Sub
#Region " Windows Form Designer generated code "

Public Sub New(ByVal arg1 As String)
MyBase.New()

'This call is required by the Windows Form Designer.
InitializeComponent()

'Add any initialization after the InitializeComponent() call

End Sub

#end region
Private Sub Button1_Click(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Button1.Click

MsgBox(strArg1)

End Sub

VJ
(please do check for syntax and typos!!)

"Becker" <be*@benbecker.net> wrote in message
news:up*************@TK2MSFTNGP15.phx.gbl...
I have a program that I can drag and drop files to. I would also like to
add this to the sendto menu so that users could right click a file and
choose to "send to" my program. My only problem is I have no idea what
event to handle in my program to accept the "send to" action.

Any help, suggested reading or examples is greatly appreciated!

Thanks,
Ben

Nov 21 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
32599
by: BadOmen | last post by:
I want my program to send a mouse click to the window at the current mouse position, how do I do that? Example: I have my mouse over a button in Word and then my program is sending the left...
0
913
by: zhimin | last post by:
Hi, I'm writing a program to send large file(100m) through dotnet using TCPListener & TCPClient, I'm sending the file with a ask and response loop: 1. Client send a flag 1 to server indicate it...
3
9087
by: Sara | last post by:
HI, I want to code a program to detect GSM mobile (any kind) which connected through serial port to computer and then be able to send SMS through this mobile phone to other mobile phones, could...
15
8562
by: cj | last post by:
How can I get a button in VB to send the contents of a text box via email in a manner similar to the "Send To\Mail Recipient" functionality that you can select via right clicking a file in Windows...
3
2654
by: growse | last post by:
Right, I've got a 2 c# programs here. Lets call them A and B. My aim is to send a simple string from B to A. A is always running. I've overridden the WndProc method to give me messages that are...
3
4261
by: BuddyWork | last post by:
Hello, Could someone please explain why the Socket.Send is slow to send to the same process it sending from. Eg. Process1 calls Socket.Send which sends to the same IP address and port, the...
0
3234
by: Atenza | last post by:
Hi all, I develop an VB6 program to send email by using CDOSYS.DLL. It works fine as follow: Dim iMsg As New CDO.Message Dim iDsrc As CDO.IDataSource Set iDsrc = iMsg ' (QueryInterface)...
14
2264
by: Professor Yonce | last post by:
I have made form for E-Mail. I have entered code but the Import system does not work. It has squiggly line underneath it showing it is not communicating. It Will not build. Public Class...
5
4944
by: Mirxon | last post by:
Hello, I'm working on a C program under Ubuntu. It's basd on socket. Browser calls a client cgi (C program), and send some parameters to server (C program). Server runs another program...
6
6626
by: terry | last post by:
Hi, I am trying to send a character to '/dev/ttyS0' and expect the same character and upon receipt I want to send another character. I tired with Pyserial but in vain. Test Set up: 1. Send...
0
7188
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7063
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7313
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6970
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7441
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
4663
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3156
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3146
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1489
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.