Solved

Changing the properties of a DLL

Posted on 2003-11-15
11
282 Views
Last Modified: 2012-05-04
Here's the situation.  We're using a 3rd party software product which is no longer being supported.

In a certain part of the application, the user is asked to choose between two radio buttons.   However, we don't want the users to make this choice:  we always want them to choose the 1st of the two radio buttons.

Now we know the DLL file this screen is contained within.  What we'd like to do is somehow access this DLL (we know it's written in VB 6.0) and set the properties of the one radio button to be NOT visible.  

We have ZERO access to any source code, and the company that bought our vendor no longer supports this product and is asking some astronomical amount of money to fix this issue.  

Any hints, tips or suggestions are greatly appreciated.  
0
Comment
Question by:EschbacherG
  • 4
  • 3
  • 2
  • +1
11 Comments
 
LVL 28

Accepted Solution

by:
AzraSound earned 500 total points
ID: 9755118
You could use code like this to find the handle to that radio button:
http://www.mvps.org/vbnet/index.html?code/enums/enumwindowsdemo.htm

And then you use something like this to hide it:

'declarations
Private Declare Function ShowWindow Lib "user32" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Private Const SW_HIDE = 0

'hide button
Call ShowWindow(radioWindowHandle, SW_HIDE)
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 9756959
Please maintain your open questions:

1 10/06/2003 250 Lotus Notes agent to download entire doc...  Open Lotus Notes
2 09/29/2003 333 Forwarding emails is slow  Open Lotus Notes
3 09/12/2003 250 Network Neighborhood information...  Open Windows NT Networking
4 08/20/2003 404 Parse an XML file and split it into smal...  Open XML

Thanks,
Anthony
0
 
LVL 2

Author Comment

by:EschbacherG
ID: 9760199
acperkins....

Those questions are still open because they haven't been satisfactorily answered.  But thanks for the unfriendly reminder.

As to my current question, I have found a tool that might, and i'm wondering if anyone had similar experiences with it.

It's called PE-Explorer.  It's a disassembler for portable-executable files, and it allows you to edit some of the resources.  On DLL's related to AOL instant messenger, I was able to see and edit various popup screens.  Not as much luck with my DLLs.

AzraSound,

We initially looked into something along your suggestions.  What we had was a program running in the background that would periodically grab handles to windows, and by comparing the window title, we could tell if the users were where they belonged.  (If they selected the wrong radio button, it would bring them to another window).

However, our management described this as being too much of a "kludge", and in our production environment, it was decided that having programs watching programs added to elements of instability.  

Does anyone else have experience with editing resources?  I've tried a few programs (Resource Hacker) as well as just looking at the Hex code, but couldn't find anything good.

Thanks for any assistance!
0
3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 9760411
>>Those questions are still open because they haven't been satisfactorily answered.<<
The chances that someone will answer a question that is nearly 3 months old is exaclty 0.
Questions that have gone more than 21 days without feedback are considered technically abandoned.

>>But thanks for the unfriendly reminder.<<
I am sorry you feel that way.  Feel free to post a message in Community Support, if you believe my comments are inappropriate.  If not please, please go ahead and maintain those questions.

Thanks,
Anthony
0
 
LVL 28

Assisted Solution

by:AzraSound
AzraSound earned 500 total points
ID: 9761019
"Reading Data from Local or External Library Resources"
http://www.vbaccelerator.com/codelib/resource/extres.htm
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 9761442
Thank you for maintaining your open questions, but I believe you may have overlooked these two:

1 08/20/2003 404 Parse an XML file and split it into smal...  Open XML
2 09/12/2003 250 Network Neighborhood information...  Open Windows NT Networking

Thanks,
Anthony
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 10143385
And now we are just down to this question and this other one:
http://www.experts-exchange.com/Networking/WinNT_Networking/Q_20737233.html

I appreciate the effort keeping up with your open questions.
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 10548441
EschbacherG, an EE Moderator will delete this for you.
Moderator, my recommended disposition is:

    DELETE this question (refund points).
    *** AzraSound's link shows how to read, but not change a resource.
    *** No PAQworthy answer here.

Dan Rollins -- EE database cleanup volunteer
0
 
LVL 28

Expert Comment

by:AzraSound
ID: 10550346
To be honest, I never understood the logic behind accessing/changing resources since the issue was with hiding a radio button.
0
 
LVL 2

Author Comment

by:EschbacherG
ID: 10551394
My original hope was that there was a way to view and change the resources within a DLL, allowing us to disable the radio button in question.   While Azra's recommendation looks good, it would require an external program peeking into to disable it.    We currently have a temporary fix like that:  we have a program that constantly monitors for a Window title that is the title that appears if the user clicked on the wrong radio button.  The problem is the client thinks of this as a real kludge, and was looking for a cleaner way.  

In the end, we opted for a very simple solution:  a big email out to our user population reminding them to never click it.   We are also upgrading our software to a newer version, and the vender has taken our recommendation and implemented it.  

(FYI:  The real this is a big problem is that the software is used to reconcile point-of-sale transactions, involving  large checks that get mailed in to a large city government.  By choosing the wrong radio button, it changes the way the money is reconciled, messes up the nightly batch job and the generated reports).  

Thanks again for your assistance guys.  
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question