473,327 Members | 2,069 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Create control at runtime with process

Hi

I want to know if it's possible to create a control at runtime in a different process than the main form

There is a fonction I try but I have a message that tell me I can create control on the parent process

Public sub cmdOpenFile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdOpenFile.Clic
Dim thInitForm As New Thread(AddressOf InitForm
Tr
ofdDocWord.ShowDialog(Me
If Not ofdDocWord.FileName = "" The
wdDoc = New Word.DocumentClas
wdApp = New Word.ApplicationClas
wdDoc = wdApp.Documents.Open(ofdDocWord.FileName
fct.FormMe = M
thInitForm.Start(
tbcGeneral.Enabled = Tru
End I
Catc
MsgBox(Err.GetException.ToString
wdApp.Quit(
wdDoc = Nothin
End Tr
End su

Public Sub InitForm(
'function to init all the information to create contro
fct.Var = fct.InitVarTab(Application.StartupPath & "\Variable", wdApp
'pass the parent control to the other clas
fct.AddObjTemp(tbcGeneral
'create the control on the parent control (here is a TabControl
fct.InitFormulaire(
End Su

someone have an idea

Thanks
Nov 20 '05 #1
0 1946

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

Similar topics

1
by: Hal Vaughan | last post by:
I've been using Runtime.exec() like this: Runtime rt = Runtime.getRuntime(); try {Process p = rt.exec("MyCommand.bat");} catch (Exception e) {do stuff} When I start my Java classes, I start...
2
by: uwnewsgroup | last post by:
When I was using Runtime.exec(String cmd) to run a unix utility (join), and try to get its standard output by using Process.getOutputStream(), it blocks forever. I tried it using Java 1.4 and...
0
by: don | last post by:
hello all, msdn says this about using a dotnet windows control library in activex environment... You have to write one relatively small piece of code to make your .NET control accessible to...
7
by: dog | last post by:
I've seen plenty of articles on this topic but none of them have been able to solve my problem. I am working with an Access 97 database on an NT4.0 machine, which has many Access reports. I...
15
by: Amit D.Shinde | last post by:
I am adding a new picturebox control at runtime on the form How can i create click event handler for this control Amit Shinde
3
by: Amjad | last post by:
Hi, I just wrote a test Windows Service that creates a text file on startup (please see my code below). The file is never created. Protected Overrides Sub OnStart(ByVal args() As String) Dim...
2
by: john | last post by:
Maybe I haven't had that "a-ha" moment yet, but I think the new approach to web projects is a step in the wrong direction. My main beef is that control over the assembly generation process has...
6
by: shapper | last post by:
Hello, How to create a CSS StyleSheet at runtime and added it an Asp:Label? I am using Asp.Net 2.0. Thanks, Miguel
1
by: henrymania | last post by:
Am writing a code for database backup....by backupservlet is as given below i get the following exception
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.