I have designed a custom control and have been trying to set the TagPrefix and ToolBoxBitmap image to the control, but none of it is working!
Adding the TagPrefix to the control
To set the TagPrefix it's says to do this
When I add my control to the page it shows up as this in the HTMLVB Code:
'Within the AssemblyInfo.vb file add this Imports System.Web.UI '<Assembly: TagPrefix("Namespace Name", "TagPrefix")> <Assembly: TagPrefix("JHAControls", "JHA")>
the TagPrefix should be "JHA", not "cc1", which is the default.Code:<%@ Register TagPrefix="cc1" Namespace="JHACustomControls.JHAControls" Assembly="JHACustomControls" %>
Why doesn't this doesn't work!?
Adding an icon to the custom control
To add an icon to the custom control, it says to do this.
Assuming the icon is the same name as your class, which it is (JHATextBox class, and JHATextBox.bmp icon)
1) Create a 16x16 pixel bmp icon. which I did.
2) Add the icon to the project, which I did.
3) Set the icons build action to "Embedded Resource", which I did
4) Rebuild the project and the icon will display in the toolbox when the control is added.
This doesn't work either, I still get the default "gears" icon.
I can get the icon to work, but only if I specify the absolute path to the file (C:\MyFolder\MyFile.bmp). But then the control (.dll file) doesn't work on another computer unless the image exists in the same location on that computer.
Anyone know why these aren't working????
