|
Hello all,
Is it possible to copy a vb6 window (a ThunderRT6FormDC) and all its contents and display them in real-time inside of a different window. I currently have a third party app, and I want to display one of its sub-frames inside of my own program. The particular window I'm interested in doesn't accept any user input, it just displays information. Is there any way of copying the subframe, is it possible to simultaneously display 1 window in more than one location, would I have to make the third-party program's main window a child window in my program. I'm basically wondering 1) is this possible, 2) how would I do it. If you need me to explain it better, just let me know. Thanks in advance.
Brandon Caesar
|
|
|
|
|
What you want to do is POSSIBLE, but very difficult to pull off. What you have to do is create a new device context for the other application to draw on, then convince the other window to draw itself to the new context. There is nothing in the .NET Framework that will help you with this.
You might want to look into VNC libraries to help. They use approximately the same technique to do what PCAnywhere does, remotely view another machines desktop and control it. You'll have to adapt the technique to "remotely" trick the other app into drawing itself onto a device context that is your form.
This is by no means easy and information on the subject is very sparse. The question you should be asking is "Is the investment in effort worth it?"
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I know that this is probly how the control was made but is there a way to adjust the scroll bar to be wider.
1. Out of clutter, find simplicity.
2. From discord, find harmony.
3. In the middle of difficulty lies opportunity.
Albert Einstein
three rules of work
|
|
|
|
|
i have a problem regarding master.
hmm..
i am currently doing a project which requires me to design a template using master. and i have no idea on how to add my pictures,etc to the master page. i also dun know how to put the template (master) to my aspx.
can someone help me solve this problem..?
thanks a million.
-DarkangeL-
|
|
|
|
|
How about asking ASP.NET specific questions in the ASP.NET Forum[^].
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
|
To me has fallen the task of documenting an in-house database created in OLE 2.0. This DB is accessed only through an API of which there is no source code. Through attrition and evidently poor documentation, the DB layout is basically lost. It is also quite complex with subsequent programmers, who did not understand it, jury rigging it to add functionality to it. Viewing it in Docfile Viewer does show the various "tables" within the DB, and the Uni-Code data is plain to see. Trying to traverse the DB manually and figure out how the system of pointers is working is making no sense to me. Of course without the layout, it's hard to tell what IS a pointer within the DB. I have worked with DB's of a similar nature and complexity before where we did have the layout and was successful with those. Creating a simple record in this DB using the existing software and then trying to see the before and after in simple additions to the data are not working for me.
My question is: Is there anyone that could give me some pointers on where to go with this? Are there good tools to use? I do have the C++ debugger for the executable only (no source code, remember) and the Doc File Viewer.
Sheljo
|
|
|
|
|
OLE stands for Object Linking and Embeddeding. It's most definately not a database engine. So, from your description, it looks like this is a custom implementation for some kind of database, and a sad excuse for the original programmers to not use a REAL database.
It COULD be an embedded Access database, but I doubt it. I also doubt you're going to find much in the way of documentation to pull this out. If you can't create a record in this thing or find patterns in the data to try and reconstruct the table layouts, you're pretty much screwed.
The question isn't "How do I get the data out of this or find the table layouts?". It's "How much time do we want to spend on this compared to scrapping it and rewriting the thing from scratch?"
I think you know what my suggestion would be.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
"embedded access database" does seem to describe it. Yes, not an real DB engien. There are actual images etc. that get embedded into the DB.
Thank you for your opinion!!
Sheljo
|
|
|
|
|
|
Hello!
How do you create a shortcut for a specific file under Application folder? I am working on Setup deployment project and whenever I create a shortcut, it doesn't place it under the folder which I created under User's program menu.
The confusion occurs when I create a shortcut because I have to assign a targeted application to shortcut but when I click the BROWSE button to see its properties, there is a field called (Target) the help about it says that "specifies application to be lunched by the shortcut" however when I click the Browse button, it shows only the folders not executable applications under selected folder. What if there are more than one executable files under Application's folder. How could it know which one to point?
Would you please explain to me how does it work and how can I accomplish creating a shortcut for a specific application under Application folder?
Thank You!
Bedri
|
|
|
|
|
Using Oledb how to collect the tables in .Net. Any one can help
sonj
|
|
|
|
|
All you have to do is Google[^] for it. There are plenty of examples.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I asked how do I collect in VB.Net not in vb6. Could post sample code if you have
Johnson
|
|
|
|
|
You're not understanding the examples. The table information your looking for is stored in a table itself! All you have to do is run a query, just like any other SELECT query, to return the data in a DataSet, or use a DataReader instead.
SELECT * FROM MSysObjects
WHERE (Name Not Like "MSys*") AND (Type In (1,4,6))
ORDER BY Name
Type 1 - normal tables
Type 4 - ODBC linked tables
Type 6 - Other linked tables (like SQL)
Do you know how to use the OleDbCommand, OleDbConnection, DataSet, DataReader, ... objects?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I very thankfull to giving info with Patience. I will try as you said.
Thanks
Johnson
|
|
|
|
|
Hi there,
I had been for over 3 days trying to solve this problem and I have no clue of what's wrong.
I'm trying to create a Dynamic DNS service using only one DNS Server (dns.firmaware.com), but created a second NS record (dns2.firmaware.com) with the same IP address.
First of all I've created a small app in VB .net that updates (using WMI) Microsoft DNS Server whenever an IP change was reported.
It creates different zones for each sub-domain and adds NS records, updates SOA record to change the TTL and MinimumTTL and finally adds/updates the A record.
I know that zone creation/update is working fine because I tested my VB .net several times and checked that Microsoft DNS entries were created/updated.
After checking all that I created a record like “test.gimmeall.com” and resolved it from my home PC. Using “ipconfig /displaydns” I checked that “test.gimmeall.com” had the following values:
localhost
----------------------------------------
Record data . . . . . : test.gimmeall.com
Record type . . . . . : 1
TTL . . . . . . . . . . . : 60
Data length. . . : 4
Section. . . . . . . . . . : Answer
A record (host) . . : 213.13.100.111
So, TTL was fine, if I changed test.gimmeall.com’s A record, after 60 seconds it would be updated, BUT that’s not happening because, after my update, when I ping the same host again it returns the same IP address and when I type “ipconfig /displaydns” it returns the following result:
----------------------------------------
Record data . . . . . : test.gimmeall.com
Record type . . . . . : 1
TTL . . . . . . . . . . . : 85823
Data length. . . : 4
Section. . . . . . . . . . : Answer
A record (host) . . : 213.13.100.111
It looks like that ISP or something else is caching “test.gimmeall.com” with invalid values, but it’s not an ISP problem because tried from different ISP companies and always had the same result.
Can you help me please?
I would be very thankful.
Regards,
Filipe Freire
|
|
|
|
|
I think your misunderstanding with /displaydns is showing you. It's not showing the DNS cache on the server, but rather the DNS Resolver cache on YOUR workstation. Do an ipconfig /flushdns before you try to resolve the name to it's new address from your workstation.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Sorry, forgot to say that.
Even if I flush my machine DNS cache it gets the same result.
But one strange thing happened, now it works fine.
Sometimes it works, some don't. :S
Had a great lunch, think I'm going to take a nap
If you can help me with anything else please answer.
Thank you,
Filipe Freire
|
|
|
|
|
It could also be that the server-side, too, is caching the lookup. Datbase operations are kind of expensive, so if the server can do this once, cache the result for a little while.
You might want to set the TTL for the record to 1 second. This will keep everyone from caching the result for more than that time and force the client to do to the DNS server to resolve the name.
You can also do this[^] on XP/2003 machines to force the client to drop it's cached result after 1 second, no matter what the record's TTL says.
It'll also force the cache on the server side to drop the cached result after 1 second, focing it to go to the database to resolve the name.
To alter the caching of results on the DNS Server itself, you'll have to consult the docs on what server your using.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi,
Is there any way to check if File.Open fails? In my code i am trying to copy a newly created file in one directory to another, but I want to make sure the file creation is complete, if not i will have to wait and try File.Open again.
Also, when i am done the File.Open, i couldn't find a way to close the file. Or i don't have to close it before i start copying that file to another directory?
|
|
|
|
|
If the Open fails, it'll throw an exception. Just wrap your code in a Try/Catch block to catch it.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi All,
I am using "USB to serial port converter" to program my USB port.As soon as the USB cable is plugged-in the driver installed allocates a COM port number to the USB Port. So usually the last allocated port number is for USB.In my program when the user opts for communiocation over USB port i will find all the valid ports in the pc and assume the last port number as the USB port number.If the USB cable is not connected then no COM Port number is allocated to USB port.So the method i am using to find out the COM port number allocatted USB port is not robust method. So i just want to know whether there is any method to find out the USB cable connected to the USB port through VB code.. Somebody help me with this.
Thanx in Advance,
Sushma
|
|
|
|
|
I am attempting my first ever drag and drop: basically I want to drag from a picture to a button (or any other control like a picture or panel) and note the co-ordinates of the point where the drop actually occurs.
The DragEventArgs has properties X and Y which, I understand, are meant to be the co-ordinates where the mouse is when the drop event occurs.
My problem is that, every time I run the same program; drag the same control to the same place the co-ordinates are different!!!
{341,379} {363,408} {385,436} {296,320} {275,291} and so on ......
Can anyone help? Thanks
Deemo
Private Sub PictureBox1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseDown<br />
PictureBox1.DoDragDrop(PictureBox1.Name, DragDropEffects.Copy)<br />
<br />
End Sub<br />
<br />
Private Sub button3_DragDrop(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles Button3.DragDrop<br />
<br />
Dim pt As New Point(e.X, e.Y)<br />
<br />
TextBox3.Text = pt.ToString<br />
End Sub
|
|
|
|
|
You need to know two things for this. The coordinate system of .Net is based upon the container you drop something on. This means if you hit on a button you will get the coordinates relative to its top left corner.
However the drag & drop coordinates are absolute, thus from the top left corner of the desktop. To get the coordinates for the drop you will need to translate them to relative coordinates. You can do this with PointToScreen and PointToClient. If correct this should solve you're problem.
Related documentation:
PointToClient
PointToScreen
|
|
|
|
|