So, it appears there is a bug with the WebImageButton. If we the "Enabled" property through server-side code, then when using
javascript, the passing a false to the "setEnabled" js method of the "button" object will internally change the enabled status to false,
but the UI will not change accordingly. The text is not "greyed" out. This is using the "LucidDream" CSS, if that is at all relevant.
If a button is disabled through "server-side", then no problems. I can see the text being greyed out when setEnabled is passed a
"false" and then looking normal when passed a "true" value.
Paul
any work-around would be appreciated.
I was able to trace a issue down into an Infragistics component and am fairly sure I would be able to push a bug fix to you guys, but need to be able to confirm by somehow using the provided source code in my solution to verify my findings or not. Ran out of time to get it sorted now, but hope to get back to it this evening.
I hope to determine cause later tonight and if I can compile the Infragistics shared DLL, I will be able to verify a fix or not.
If I find a solution through a source code update, then will post again and hopefully, I can hopefully push a solution to you guys.
You guys do not make it easy to debug your libraries. You provide the source and the symbols, but one critical symbols file is missing from the ZIP, and then initially building the source code results in an error within the jQuery project due to duplicate source file entries for framework/AssemblyVersion.cs in the project file.
Even when you have a compiled library using the custom built DLL's, it is impossible to load and use them because I keep getting the following error:
Parser Error Message: The base class includes the field 'DefaultScriptManager', but its type (Infragistics.Web.UI.WebScriptManager) is not compatible with the type of control (Infragistics.Web.UI.WebScriptManager).
Obviously, this is a result of some version DLL issues because of DLL's loaded in the GAC, but how can one debug your solution files
Hello Pavel,Thank you for posting in our forums! To enable or disable the WebImageButton click On the client side you can use the setEnabled method as :http://help.infragistics.com/Doc/ASPNET/2015.2/CLR4.0/?page=WebImageButton_Object_CSOM.htmlYou can use ig_getWebControlById function and providing the ClientID or UniqueID as a parameter to set setEnabled property.or you can use oButtonwhich is reference to the JavaScript object that represents WebImageButton.
<!DOCTYPE html>
<script type="text/javascript"> function Click(oButton, oEvent) { //oButton.setEnabled(false);
var button = ig_getWebControlById("WebImageButton1"); button.setEnabled(false);
}</script><html xmlns="http://www.w3.org/1999/xhtml"><head runat="server"> <title></title></head> <body> <form id="form1" runat="server"> <div> <h3>Enabled Property of a Web Control</h3> <igtxt:WebImageButton ID="WebImageButton1" runat="server" Text="Click Me" ToolTip="Image button"> <ClientSideEvents Click="Click"></ClientSideEvents> </igtxt:WebImageButton> </div> </form></body></html>
if this sample is not an accurate demonstration of what you're trying to do, please feel free to modify it and send it back, or send a small sample project of your own if you have one.Please let me know if I can provide any further assistance.
This is my problem:
1) When the button is disabled through server side (via a postback), then issuing a the setEnabled command through javascript works fine.
2) When the button is enabled through server side (via a postback), then issuing the setEnabled command through javascript does not update the UI state of the button.
I have attached an example. This sample simulates my situation where if the initial state of the button is enabled, then if you remove text from the textbox and the length
of the text is 0, it will disable the state of the button. Anything greater than 0 characters will enable the state. If we set the state as "disabled", (which is another scenario)in my application, then the CSOM works perfectly and the UI state works well. I know exactly what is missing in the code. I could even point it to you as I have debugged it to the Javascript layer. I could even fix it myself, if I had the ability to successfully build a custom binary into my solution. I could even send you the fix once I have confirmed it, but debugging/building the Infragistics binaries into my solution is making it impossible. I have opened a ticket for this as well.
woops, I made an statement error: in my description, if you delete text from the textbox (when the button state is initially enabled) and the length is zero, the button should end up being disabled, but the UI statement doesn't change.
Hello Pavel,
The issue is that the button preset you're using (I assume it's the Default preset) doesn’t configure disabled state styling.
What I can suggest you to try as a solution is to configure the DisabledAppearance of the button like this:
<igtxt:WebImageButton ID="WebImageButton3" runat="server" Text="Click me 2" Enabled="false">
<DisabledAppearance>
<ButtonStyle ForeColor="GrayText">
</ButtonStyle>
</DisabledAppearance>
</igtxt:WebImageButton>
This will make button's text grayed out when you disable the button.
Hope this helps,Martin PavlovInfragistics, Inc.
I can't seem to find the "Development Issues" tab.
Hello Pavel,I have investigated your issue, and I have asked our engineering staff to examine this further. To ensure that it will receive attention, I have logged this behavior in our internal tracking system with a Development ID of 215075 .The next step will be for a developer to review my investigation and confirm my findings or to offer a fix, or other resolution.I will leave this case open and update you with any new information after the review. You can also continue to send updates to this case at any time.You can view the status of the development issue connected to this case by selecting the "Development Issues" tab when viewing this case on the web site. Please let me know if you need more information.