Solved

Add Objects To IE

Posted on 2004-10-03
6
207 Views
Last Modified: 2010-04-05
how can i add a TEdit and a TLabel (delphi objects)
to internet Explorer Toolbox?
0
Comment
Question by:alimoradi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
6 Comments
 
LVL 9

Accepted Solution

by:
ginsonic earned 250 total points
ID: 12211164
This code show how to add a button. Just replace button with your needed vcl.

{
 This is a simple little example that allows you to add a button
 to Internet Explorer 3.0 or above
 Values:
 ButtonText := The text you want to be displayed at the bottom of the button
 MenuText := The tools option at the top of IE will now contain
 a reference to your program.
 MenuStatusbar := Script option we are not using this object. (Ignore)
 CLSID := Your classID. I won`t explain it because its complex.
 That it has to unique. You can use GUIDTOSTRING
 To create a new CLSID with the unit ActiveX.

 Default Visible := Display it.
 Exec := Your program path to execute.
 Hoticon := (Mouse Over Event) ImageIndex in shell32.dll i've picked 4
 Icon := I've selected to display shell32.dll image 4.
}


procedure CreateExplorerButton(Path: string);
const
  Tagit = '\{10954C80-4F0F-11d3-B17C-00C0DFE39736}\';
var
  Reg: TRegistry;
  Path: string;
  Path1: string;
  Merge: string;
begin
  Path := 'c:\your_program_path';
  Reg := TRegistry.Create;
  try
    with Reg do
    begin
      RootKey := HKEY_LOCAL_MACHINE;
      Path1 := 'Software\Microsoft\Internet Explorer\Extensions';
      Merge := Path1 + Tagit;
      OpenKey(Merge, True);
      WriteString('ButtonText', 'ButtonText');
      WriteString('MenuText', 'Tools Menu Item');
      WriteString('MenuStatusBar', 'Run Script');
      WriteString('ClSid', '{1FBA04EE-3024-11d2-8F1F-0000F87ABD16}');
      WriteString('Default Visible', 'Yes');
      WriteString('Exec', Path + '\ProgramName.exe');
      WriteString('HotIcon', ',4');
      WriteString('Icon', ',4');
    end
  finally
    Reg.CloseKey;
    Reg.Free;
  end;
end;
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 12211167
Not my code. Just found on past on net.
0
 
LVL 6

Expert Comment

by:Amir Azhdari
ID: 12211286
to add a tlabel or tedit , I think you should add a new toolbar first
take a look in the registry address :
HKEY_CLASSES_ROOT\CLSID
it's CLSID of Internet Toolbar
{5E6AB780-7743-11CF-A12B-00AA004AE837}
but I don't know how to create that first
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 13180081
no comments for a long time!
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
In this video, viewers will be given step by step instructions on adjusting mouse, pointer and cursor visibility in Microsoft Windows 10. The video seeks to educate those who are struggling with the new Windows 10 Graphical User Interface. Change Cu…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …

707 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