473,698 Members | 2,411 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Getting parent window reference

Hi
Is there a way is a 'class library' to get the reference to window of
application that uses the library ?

I'm using class library to create a custom command for a closed source
application (GeoMedia), so obviously I can't make it to pass this
reference to my lib as a method parameter.

--
Rudy
Nov 15 '05 #1
1 5572
Hi Rudy,

I think calling WinAPI functions like FindWindow through P/Invoke might
help. But there are lots of potential caveats - the parent window might be
owned by another thread, for example. I think there is good reason why the
window handle is not given to custom commands. I'd still, however, suggest
referring to the GeoMedia manual - I hope they should have said something
about that there.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Rudy" <R.*********@el ka.pw.edu.pl> wrote in message
news:bk******** ***@foka1.acn.p l...
Hi
Is there a way is a 'class library' to get the reference to window of
application that uses the library ?

I'm using class library to create a custom command for a closed source
application (GeoMedia), so obviously I can't make it to pass this
reference to my lib as a method parameter.

--
Rudy


Nov 15 '05 #2

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

Similar topics

1
2168
by: DROdio | last post by:
I have a parent window that calls a popup, but via a semi convoluted process where it seems to lose its parent designation. I want that pop up to have a link which will a) close the pop up and b) redirect this "semi" parent window to another URL. I could name the semi-parent window something, if that would help. All the ideas I've seen online have to do with calling back to parent windows, but they don't work for me.
4
6288
by: JJ | last post by:
I'm working with a web site that has frames defined as: <frameset rows="60,*" frameborder="yes" border="0" framespacing="0" cols="*" bordercolor="#eeeeee" topmargin="0" leftmargin="0" marginheight="0" marginwidth="0"> <frame name="topFrame" scrolling="auto" src="top.asp" bordercolor="#cccc66" frameborder="yes" topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" framespacing="0"> <frameset cols="180,*" frameborder="YES"...
26
45507
by: Dave Hammond | last post by:
In document "A.html" I have defined a function and within the document body have included an IFRAME element who's source is document "B.html". In document "B.html" I am trying to call the function defined in "A.html", but every attempt results in an "is not a function" error. I have tried to invoke the function using parent.document.funcname(), top.document.funcname(), and various other identifying methods, but all result in the above...
4
10489
by: Davey | last post by:
I have a website which has a popup window (this only opens when the user chooses to open it). In the popup window I have a <select> control which lists a selection of "classes". Each class has a description and a class_id (stored in the value attribute of each option). The user will then select a class from the drop-down list. What I want to do is have a control in the parent browser window which can store the class_id and the...
3
2741
by: RobG | last post by:
In Firefox if an HTML page is not hosted inside a frame or iframe, the following return true: (window === window.self); (window === window.parent); But in IE they return false (using == returns true for both). Can someone explain why?
2
19230
by: Robert Degen | last post by:
Hello, I got a little problem. Seems very simple: * I want to open a popup window * Popup-window uses data from its father window. BUT a parent.window does NOT point to the real parents window. Alerting parent.window.location.href shows me, I'm at the wrong window location.
5
8037
by: midnight_use_only | last post by:
hi all, quick question, how do you submit a form to a parent window from a child popup window? i have the following and all online documentation *suggests* that it should work but it does NOT: // Parent window: <script language="JavaScript"> function popup(url, name) { window.open(url, name, "width=800,height=600,scrollbars=yes");
4
2235
by: Ravi Kishore | last post by:
Hi all, I have a problem while sending the data to and fro a JSP page. When i click a link on a JSP page(say parent.jsp), i have to open a diff page(say child.jsp), get the data from that page and pass that data to the parent.jsp and do some actions with the data i recently got. I am not using window.open(...)..so i definitely can't use opener object. Also i can't use form.action(parent.jsp?...) as i have to do database hits to open the...
0
8675
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
8604
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
9160
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...
0
8862
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...
0
7729
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6521
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
4619
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2331
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2002
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.