iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
I'm trying to set a FomatConditon based upon a value in the grid. I've used both the designer and code and think I have come up with a bug. If the Column that you are testing is NULL, then the Grid fails with an Object Refreence Not Set, but in my case it fails within my Master Page. If I change the column I am looking at to one that doens't contain any NULL values then the format condition displays properly.
Heres the code
Protected Sub WebGrid1_InitializeLayout(ByVal sender As Object, ByVal e As ISNet.WebUI.WebGrid.LayoutEventArgs) Handles WebGrid1.InitializeLayout ' specific row Dim a As WebGridFormatCondition = New WebGridFormatCondition() a.ColumnMember = "EXEMPTION_FLAG" a.ConditionText = "y" a.Name = "Format1" a.FormatStyle.CssClass = "flag" 'a.FormatStyle.ForeColor = System.Drawing.Color.Red a.TargetObject = ISNet.WebUI.WebGrid.TargetObjectType.Row WebGrid1.RootTable.FormatConditions.Add(a) End Sub
The field EXEMPTION_FLAG maybe "y' but in most cases is NULL.
Like I said if I change EXEMPTION_FLAG to another field that doesn't have any NULL's then it works.
Is this a bug or did I miss something?
I am using an ISDataSource looking at a DataSet for the data source of the grid.
Thanks
John
For such scenario you will have to use CustomConditionText property. Please use
a.CustomConditionText = "EXEMPTION_FLAG = 'y'";
Instead of
a.ColumnMember = "EXEMPTION_FLAG";a.ConditionText = "y";
If you have null value cell in the datasource.
Thanks worked perfectly...
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname