473,722 Members | 2,240 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

activate event not fired ? ?

hi there
here is my problem :
there is a main form (frmMain) which calls a searchForm (frmSearch). Then i
select an item (from the returned ones) and open a third form (frmData).
Taking from there i can either :
A. open a fourth form (frmComment) which is just a textbox and a button (and
should return the text entered in the textbox into frmData)
B. open a word document ,and paste its contents into a richtextbox in frmData
The problem is that whichever i do, the frmData 's activated Event isn't
fired when i clos frmComment or the word Application.
shouldn't it be the case ?
Nov 21 '05 #1
5 2820
Juststarter

Are it
MDI forms
or
Showdialog forms
or
Forms all showed separatly and all in the same time active on the screen ?

Cor

"juststarte r"
hi there
here is my problem :
there is a main form (frmMain) which calls a searchForm (frmSearch). Then
i
select an item (from the returned ones) and open a third form (frmData).
Taking from there i can either :
A. open a fourth form (frmComment) which is just a textbox and a button
(and
should return the text entered in the textbox into frmData)
B. open a word document ,and paste its contents into a richtextbox in
frmData
The problem is that whichever i do, the frmData 's activated Event isn't
fired when i clos frmComment or the word Application.
shouldn't it be the case ?

Nov 21 '05 #2
frmSearch and frmData are mdi children ( frmSearch.mdipa rent = frmMain,
frmData.mdipare nt = frmMain) and are loaded using the show() method.
frmComments is non mdi and is shown using showDialog().

"Cor Ligthert" wrote:
Juststarter

Are it
MDI forms
or
Showdialog forms
or
Forms all showed separatly and all in the same time active on the screen ?

Cor

"juststarte r"
hi there
here is my problem :
there is a main form (frmMain) which calls a searchForm (frmSearch). Then
i
select an item (from the returned ones) and open a third form (frmData).
Taking from there i can either :
A. open a fourth form (frmComment) which is just a textbox and a button
(and
should return the text entered in the textbox into frmData)
B. open a word document ,and paste its contents into a richtextbox in
frmData
The problem is that whichever i do, the frmData 's activated Event isn't
fired when i clos frmComment or the word Application.
shouldn't it be the case ?


Nov 21 '05 #3
Juststarter,

When the fromComment is showed
dim frmComment as new formComment
frmComment.show dialog
'Here is where should the operation go on when frmComment closes.

However there is in my opinion no reason for an activated event, it is
already active.

For your word application it is very dependend how you start it.
When it is with process.start you can set a

http://msdn.microsoft.com/library/de...rexittopic.asp

To get the same behaviour

I hope this helps?

Cor
"juststarte r" <ju*********@di scussions.micro soft.com>
...
frmSearch and frmData are mdi children ( frmSearch.mdipa rent = frmMain,
frmData.mdipare nt = frmMain) and are loaded using the show() method.
frmComments is non mdi and is shown using showDialog().

"Cor Ligthert" wrote:
Juststarter

Are it
MDI forms
or
Showdialog forms
or
Forms all showed separatly and all in the same time active on the screen
?

Cor

"juststarte r"
> hi there
> here is my problem :
> there is a main form (frmMain) which calls a searchForm (frmSearch).
> Then
> i
> select an item (from the returned ones) and open a third form
> (frmData).
> Taking from there i can either :
> A. open a fourth form (frmComment) which is just a textbox and a button
> (and
> should return the text entered in the textbox into frmData)
> B. open a word document ,and paste its contents into a richtextbox in
> frmData
> The problem is that whichever i do, the frmData 's activated Event
> isn't
> fired when i clos frmComment or the word Application.
> shouldn't it be the case ?


Nov 21 '05 #4
this is how i start the word application

Dim fileName As String
Dim wordapp As Word.Applicatio n
Dim document As Word.Document
fileName = Application.Sta rtupPath & "\wordDocuments \templates\temp late.dot"
wordapp = New Word.Applicatio n
wordapp.Visible = True
wordapp.Activat e()
document = wordapp.Documen ts.Open(fileNam e)

the strange thing is that the same code is also used in another form
(suppose there is as frmData2 which does the same thing (aka : opening a word
doc or opening an frmConnect form) but in the later case the code in the
activated event (of frmData2 form) is executed

do u think i should use system.diagnost ics.process.sta rt("....") ? how can i
get the process handle so that i use the waitForExit ?
i have tried
system.diagnost ics.process.sta rt("....")
a = system.diagnost ics.process.get currentprocess
but this returns the process of my vb project :(

thx for your time:)

"Cor Ligthert" wrote:
Juststarter,

When the fromComment is showed
dim frmComment as new formComment
frmComment.show dialog
'Here is where should the operation go on when frmComment closes.

However there is in my opinion no reason for an activated event, it is
already active.

For your word application it is very dependend how you start it.
When it is with process.start you can set a

http://msdn.microsoft.com/library/de...rexittopic.asp

To get the same behaviour

I hope this helps?

Cor
"juststarte r" <ju*********@di scussions.micro soft.com>
...
frmSearch and frmData are mdi children ( frmSearch.mdipa rent = frmMain,
frmData.mdipare nt = frmMain) and are loaded using the show() method.
frmComments is non mdi and is shown using showDialog().

"Cor Ligthert" wrote:
Juststarter

Are it
MDI forms
or
Showdialog forms
or
Forms all showed separatly and all in the same time active on the screen
?

Cor

"juststarte r"

> hi there
> here is my problem :
> there is a main form (frmMain) which calls a searchForm (frmSearch).
> Then
> i
> select an item (from the returned ones) and open a third form
> (frmData).
> Taking from there i can either :
> A. open a fourth form (frmComment) which is just a textbox and a button
> (and
> should return the text entered in the textbox into frmData)
> B. open a word document ,and paste its contents into a richtextbox in
> frmData
> The problem is that whichever i do, the frmData 's activated Event
> isn't
> fired when i clos frmComment or the word Application.
> shouldn't it be the case ?


Nov 21 '05 #5
JustStarter,

I did a long time no word interop, so for that part you can probably better
start a new thread in this newsgroup, word interop is not a form however an
application.

My advices would certainly not be the best for that.

Cor
Nov 21 '05 #6

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

Similar topics

1
2059
by: June Homer | last post by:
I have a form which has its activate event set to maximise the form. This used to work but no long does. I have put a breakpoint in the Activate event and it is never trapped. The form is opened from the frmSwitchboard (the start up form) with a simple DoCmd.openForm "formName". I did have the min/max buttons disabled but have changed them back to enabled in case this was an issue.
9
2558
by: MLH | last post by:
Say I open a form (MyForm) in design view, then I close it and dbl-click it in the database window to open it. Shouldn't the Activate event occur in all such situations? What might the case(s) be if the Activate event does NOT fire?
0
1069
by: Brian Wilson | last post by:
According to the Access 2002 help file: "The Activate event can occur only when a form or report is visible" So why do I see two message boxes: "Activate" and "Visible=False"? ' In the form's module: Private Sub Form_Activate() MsgBox "Activate" End Sub
4
3902
by: Anatoly | last post by:
Put any control on web page. create Init event for ths control. Write Response.Write("here") inside this event. Compile\build\run. I never saw "here" string appear on web page. Why???
0
1132
by: crangel | last post by:
Hi i´m develop one app multi-document, is a similar MsWord application I have one MDI Form, that lodges several MDIChild, every time that closed one I make a trigger process, but when I close the last Form opened does not complete do it, I was using the Activate of forms to call the process but in my form father not it shoots Activate event when I close the last form child.
6
1681
by: Jeff User | last post by:
Hi I have a WebControls.DropDownList. autoPostBack is set to true. I have code (C#) in the event procedure in the code behind and it works fine. OK, now my problem is this: While in the Page_Load event, I want to be able to determine, what event, if any, caused the page to be loading. ie. maybe there are several possible user control events that could have occured. Which one brought me here? So
1
4954
by: tomlebold | last post by:
When or should the form Activate event be used? I'm working on an existing application that excutes Me.Refresh on the form Activate (Form_Activate) event. This event causes the form to try to update the current record when it should not be. I have never used this in any of my applications.
0
2022
by: tomlebold | last post by:
When or should the form Activate event be used? I'm working on an existing application that excutes Me.Refresh on the form Activate (Form_Activate) event. This event causes the form to try to update the current record when it should not be. I have never used this in any of my applications.
2
8711
by: CGatto | last post by:
Hi, I have Windows Form with several User Controls embedded within. Only one user control is visible at any one time. The user moves through the various user controls by clicking Previous and Next buttons. What I want to happen is for the individual user controls to have the ability to set focus to a specific textbox control when the user control becomes active. Normally I would handle this sort of thing via a form's activate event,...
3
3065
by: =?Utf-8?B?V2ViQnVpbGRlcjQ1MQ==?= | last post by:
In the page_load event i need to see which event fired the post back. what here allows this. I specificly want to know if the enter key was pressed. but i need to check for others. -- (i''ll be asking a lot of these, but I find C# totally way cooler than vb and there''s no go''n back!!!) thanks (as always) kes
0
8863
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8739
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9384
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9157
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9088
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6681
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5995
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4502
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
2602
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.