Hi Team Ext.Net I Want to change the icon to trigger of ComboBox, I see the property "TriggerCls", but I don't see anything efect, How Can I to do it?
Regards.
Printable View
Hi Team Ext.Net I Want to change the icon to trigger of ComboBox, I see the property "TriggerCls", but I don't see anything efect, How Can I to do it?
Regards.
Hi @osef,
Here is an example.
Example
Code:<%@ Page Language="C#" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<!DOCTYPE html>
<html>
<head runat="server">
<title>Ext.NET v2 Example</title>
<style>
.my-icon {
background-image: url(resources/images/test.png);
}
</style>
</head>
<body>
<form runat="server">
<ext:ResourceManager runat="server" />
<ext:ComboBox runat="server" TriggerCls="my-icon" />
</form>
</body>
</html>
What Ext.NET version are you using?
Please see the following sample
https://examples2.ext.net/#/Form/Tri...d/Custom_Icon/
Please note that image for trigger is complex (it should contain 5 states for button), here is an example for button
https://examples2.ext.net/Examples/F...om-trigger.gif
https://examples2.ext.net/Examples/F...om-trigger.gif
Hello!
Try the following:
Code:<%@ Page Language="C#" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<!DOCTYPE html>
<html>
<head runat="server">
<title>Ext.NET v2 Example</title>
<style>
.my-icon {
background-image: url(https://examples2.ext.net/Examples/Form/TriggerField/Custom_Icon/resources/images/custom-trigger.gif);
}
</style>
</head>
<body>
<form runat="server">
<ext:ResourceManager runat="server" />
<ext:ComboBox runat="server" TriggerCls="my-icon" />
</form>
</body>
</html>
It seems Ext.NET 2.0 has the bug, so you wrap TirggerCls value by quotes. Use the following:
Code:<%@ Page Language="C#" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<!DOCTYPE html>
<html>
<head runat="server">
<title>Ext.NET v2 Example</title>
<style>
.my-icon {
background-image: url(https://examples2.ext.net/Examples/Form/TriggerField/Custom_Icon/resources/images/custom-trigger.gif);
}
</style>
</head>
<body>
<form runat="server">
<ext:ResourceManager runat="server" />
<ext:ComboBox runat="server" TriggerCls="'my-icon'" />
</form>
</body>
</html>