473,480 Members | 2,014 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Calling VB.NET form from VB 6 EXE

Hello
I activate my vb6 application from vb.net .Now user want to be able to call
vb.net form from vb6 exe
How do I call vb.net from from vb6 source?
Do I hit some perfomances issue?
Can you show me an example of code ?
Thanks
Shell("c\folder\vb.exe", vbMaximizedFocus)


Nov 20 '05 #1
13 6476
* "Uri Dimant" <ur**@iscar.co.il> scripsit:
I activate my vb6 application from vb.net .Now user want to be able to call
vb.net form from vb6 exe
How do I call vb.net from from vb6 source?
Do I hit some perfomances issue?
Can you show me an example of code ?
Thanks
Shell("c\folder\vb.exe", vbMaximizedFocus)


Do you want to shell the VB6 executable? You can still use 'Shell', or
'System.Diagnostics.Process.Start' to do that.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #2
Hi,
Thanks
What is the code in my VB6 code I have to add in order to call let me say
form1 in VB.NET

"Herfried K. Wagner [MVP]" <hi***************@gmx.at> wrote in message
news:bt************@ID-208219.news.uni-berlin.de...
* "Uri Dimant" <ur**@iscar.co.il> scripsit:
I activate my vb6 application from vb.net .Now user want to be able to call vb.net form from vb6 exe
How do I call vb.net from from vb6 source?
Do I hit some perfomances issue?
Can you show me an example of code ?
Thanks
Shell("c\folder\vb.exe", vbMaximizedFocus)


Do you want to shell the VB6 executable? You can still use 'Shell', or
'System.Diagnostics.Process.Start' to do that.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>

Nov 20 '05 #3
"Uri Dimant" <ur**@iscar.co.il> schrieb
What is the code in my VB6 code I have to add in order to call let me
say form1 in VB.NET


You can not call a Form. You can call an executable. You may pass arguments
in the command line to the exe. In the vb.net Exe, you get the command line
using the Command function (Microsoft.VisualBasic.Interaction.Command) or
System.Environment.CommandLine or by adding "byval args() as string" to sub
main.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #4
He's using vb6, he wants to try and use vb6 and then somehow use the .net
namespaces within vb6 code.
"Armin Zingler" <az*******@freenet.de> wrote in message
news:et**************@TK2MSFTNGP11.phx.gbl...
"Uri Dimant" <ur**@iscar.co.il> schrieb
What is the code in my VB6 code I have to add in order to call let me
say form1 in VB.NET
You can not call a Form. You can call an executable. You may pass

arguments in the command line to the exe. In the vb.net Exe, you get the command line using the Command function (Microsoft.VisualBasic.Interaction.Command) or
System.Environment.CommandLine or by adding "byval args() as string" to sub main.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #5
"mrpolitics" <mr********@cinci.rr.com> schrieb
He's using vb6, he wants to try and use vb6 and then somehow use the
.net namespaces within vb6 code.


That's what I thought, too.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #6
* "Armin Zingler" <az*******@freenet.de> scripsit:
He's using vb6, he wants to try and use vb6 and then somehow use the
.net namespaces within vb6 code.


That's what I thought, too.


And that's not possible.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #7
"Herfried K. Wagner [MVP]" <hi***************@gmx.at> schrieb
* "Armin Zingler" <az*******@freenet.de> scripsit:
He's using vb6, he wants to try and use vb6 and then somehow use
the .net namespaces within vb6 code.


That's what I thought, too.


And that's not possible.


And that's what I wrote.
--
Armin

Nov 20 '05 #8
* "Armin Zingler" <az*******@freenet.de> scripsit:
He's using vb6, he wants to try and use vb6 and then somehow use
the .net namespaces within vb6 code.

That's what I thought, too.


And that's not possible.


And that's what I wrote.


Yep. My newsreader (I don't know why) didn't show your post)...

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #9
Cor
>>>My newsreader (I don't know why) didn't show your post)...

We know, do you copy this message also from Google.

:-))

Cor
Nov 20 '05 #10
* "Cor" <no*@non.com> scripsit:
My newsreader (I don't know why) didn't show your post)...


We know, do you copy this message also from Google.


No!

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #11
You can call out from unmanaged code object (VB6) to objects created in .Net
using COM Interop. See the .Net documentation for all the gory details.
There's also a lot posted on the web on how to do this.

This means, of course, that you wrap the .Net functionality in a dll created
in .Net; there's no way to call directly from VB6 into the .Net libraries.

Prester John
"mrpolitics" <mr********@cinci.rr.com> wrote in message
news:e4**************@TK2MSFTNGP11.phx.gbl...
He's using vb6, he wants to try and use vb6 and then somehow use the .net
namespaces within vb6 code.
"Armin Zingler" <az*******@freenet.de> wrote in message
news:et**************@TK2MSFTNGP11.phx.gbl...
"Uri Dimant" <ur**@iscar.co.il> schrieb
What is the code in my VB6 code I have to add in order to call let me
say form1 in VB.NET


You can not call a Form. You can call an executable. You may pass

arguments
in the command line to the exe. In the vb.net Exe, you get the command

line
using the Command function (Microsoft.VisualBasic.Interaction.Command) or System.Environment.CommandLine or by adding "byval args() as string" to

sub
main.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html


Nov 20 '05 #12
J
Whoever I responded to then tried to tell him how to get command line args
from within dot net....which was pointless because hes inside VB6....hence
my comment.

"Armin Zingler" <az*******@freenet.de> wrote in message
news:OJ**************@TK2MSFTNGP10.phx.gbl...
"Herfried K. Wagner [MVP]" <hi***************@gmx.at> schrieb
* "Armin Zingler" <az*******@freenet.de> scripsit:
> He's using vb6, he wants to try and use vb6 and then somehow use
> the .net namespaces within vb6 code.

That's what I thought, too.


And that's not possible.


And that's what I wrote.
--
Armin

Nov 20 '05 #13
"J" <J@www.com> schrieb
Whoever I responded to then tried to tell him how to get command line
args from within dot net....which was pointless because hes inside
VB6....hence my comment.


I don't see a previous message from "J" in this thread.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #14

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

Similar topics

10
600
by: headware | last post by:
I know that you can call the method of one from from inside another form by doing something like this Forms("MyForm").MyFunction(12, 34) However, you have to know that MyForm has a function...
14
2975
by: ericellsworth | last post by:
Hi, I'm trying to use a class to pass variables back and forth from a form opened in dialog mode. I have created a class which invokes a form in its show method, like so: Public Sub Show() '...
2
6592
by: mark | last post by:
I am developing an application in .Net C# that needs to restore a number of tool windows to some previous location and size. The problem I have is that when I create the form and set the Location...
2
1803
by: Renzo | last post by:
hi ! i've recently begun developing in c# and i'd like to know what's the best way of calling a form from an already instanced form ? I have done a "Login" form which I run in the Main() using...
6
1687
by: Amjad | last post by:
Hi, I want to make a project that calls and executes a function (VB code) made in a seperate file in the Application Folder. I know I can create the function in my project and call it internally,...
0
2369
by: teddysnips | last post by:
I have Search form that allows users to retrieve records into a DataGrid. There are two search criteria - a Month and a Year, which are selected from drop-down lists. There is a server-side...
3
3557
by: Opa | last post by:
Hi , I have a form with javasript which launches a popup via the showModalDialog() method. I get the dialog to open, now I am trying to first get a reference to the calling form from the popup...
7
2923
by: Lee Crabtree | last post by:
I remember when I was first getting into .NET Forms programming that there was a rather emphatic rule about not constructing a form before calling Application.Run with it. So this: ...
1
1732
by: SAL | last post by:
Hello, I'm developing this remoting app (.net 2.0) and I need to bring the server app's form to the front often. Since you can not do cross-thread communication on a form or control without using...
0
6904
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
7032
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6730
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
6873
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
5321
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4471
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
2990
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...
1
558
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
174
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.