User Profile & Activity

Hans Kristian Member
Page
of 69
Posted: February 20, 2014 1:25 AM

Hello,

Thank you for the reply.
I apologize for the inconvenience.

This issue appears due to the WebGrid doesn’t enter edit mode when you double click on the cell.

I made a WebGrid page. I bind the WebGrid to access data source (Northwind.mdb & Shippers table) and set the OnCellDblClick client event to the WebGrid as well.
In OnCellDblClick event, I try to make changes on Phone column.
Here’s the Javascript code:

function WebGrid1_OnCellDblClick(controlId, tblName, rowIndex, cellIndex, cellEl){
    var WebGrid1 = ISGetObject(controlId);
            
    var RowObject = WebGrid1.GetSelectedObject().ToRowObject()
    var CellObject = RowObject.GetCell('Phone');
    CellObject.ActivateEdit();
    CellObject.SetText("123456", true);
    CellObject.SetValue("123456");
    RowObject.SetDataChanged(); // indicates that this row's data has been changed.      
    WebGrid1.MarkEdit(); // sets the row's status as edited, as if user has typed inside the cell.
            
    return true;
}

Please kindly have review on the page as well. You could get the page from this link: http://1drv.ms/1bNO8dJ

Hope this helps.

Regards,
Hans K.

Posted: February 19, 2014 4:19 AM
Hello,

Thank you for the question regarding WebGrid.

Please kindly try to modify your javascript code from:
if (cellIndex == 17){
    grid.GetSelectedObject().ToRowObject().GetCell('ANKUNFT').SetValue(now, true);
    grid.GetSelectedObject().ToRowObject().GetCell('ANKUNFT').SetText(datum.toString());
    grid.GetSelectedObject().ToRowObject().GetCell('STATUS').SetValue('0', true);
    grid.GetSelectedObject().ToRowObject().GetCell('STATUS').SetText('Awensend');
}
if (cellIndex == 18)
{
    grid.GetSelectedObject().ToRowObject().GetCell('ABREISE').SetValue(now, true);
    grid.GetSelectedObject().ToRowObject().GetCell('ABREISE').SetText(datum.toString());
}

To:

if (cellIndex == 17)
{
    grid.GetSelectedObject().ToRowObject().GetCell('ANKUNFT').SetValue(now);
    grid.GetSelectedObject().ToRowObject().GetCell('ANKUNFT').SetText(datum.toString(), true);
    grid.GetSelectedObject().ToRowObject().GetCell('STATUS').SetValue('0');
    grid.GetSelectedObject().ToRowObject().GetCell('STATUS').SetText('Awensend', true);
}
if (cellIndex == 18)
{
    grid.GetSelectedObject().ToRowObject().GetCell('ABREISE').SetValue(now);
    grid.GetSelectedObject().ToRowObject().GetCell('ABREISE').SetText(datum.toString(), true);
}

Hope this helps.

Regards,
Hans K.

Posted: February 18, 2014 5:52 AM
Hello,

Thank you for the reply & video.

I made a SQL database, that similar with the SortingCode access database, with one table within.
Then I made another WebCombo sample. I bind the WebCombo to SQL data source (with table that I have made).

While I’m running, I try to trace the queries that happen in my SQL server using SQL Server Profiler.
The result is every query (process) that happens in my SQL server always takes time less than one second.
I get the same result when I try to see the HttpRequest profiler from browser.

Please kindly try to investigate your current Store Procedure / SQL query; perhaps there is some improvement to make the query faster.

Please kindly have review on the video as well, you could the video from this link below:
http://sdrv.ms/1lGhsU7

Regards,
Hans K.
Posted: February 13, 2014 10:01 PM

Hello,

Thank you for the question regarding WebGrid.

You could do a custom sorting in “OnCustumSort” WebGrid’s server side event.
Here’s the example snippet code regarding custom sorting:

protected void WebGrid1_CustomSort(object sender, ISNet.WebUI.WebGrid.SortEventArgs e){
    WebGridGroup sortCol;
    sortCol = e.SortColumns.GetNamedItem("ContactName");
    WebGridGroup oldSortCol;
    oldSortCol = e.SortColumns.GetNamedItem("CustomerID");
    if (oldSortCol != null)
    {
        sortCol = new WebGridGroup();
        sortCol.Table = oldSortCol.Table;
        sortCol.ColumnMember = "ContactName";
        if (e.SortColumns.GetNamedItem("CustomerID").SortOrder == SortOrder.Ascending)
        {
            sortCol.SortOrder = SortOrder.Ascending;
        }
        else if (e.SortColumns.GetNamedItem("CustomerID").SortOrder == SortOrder.Descending)
        {
            sortCol.SortOrder = SortOrder.Descending;
        }
        e.SortColumns.Remove(oldSortCol); e.SortColumns.Add(sortCol);
    }
}
With this example line of code above, if you try to sort the “CustomerID” column, it will sort “ContactName” column.
You could put any custom filter as you please.

Before you use the “OnCustomSort” event, you should set the “AutomaticSort” property to "false".
You can find the “AutomaticSort” property under “RootTable” tag.

For further information about CustomSort event, you could see in WebGrid documentation.

Hope this helps.

Regards,
Hans K.
Posted: February 12, 2014 11:39 PM
Hello,

Thank you for the reply.

Thank you for the video, but unfortunately I can’t open the video properly. Here’s what I get while I’m trying to open the video file: TeamViewerIssue.png.
I am sorry, if you don’t mind, please kindly try to upload the .tvs file to another server upload, and then provide me the download link. Or provide me another video format.

Since I can’t run your page, due to don’t have your database, I made simple table use access and WebCombo page that perhaps similar with yours.
I bind the WebCombo to access data source.
However, the WebCombo works fine on my end.

I attached my WebCombo page and the video about the result that I get on my end.
If you couldn’t get the attachment file properly, please try to follow this link below:
http://sdrv.ms/1lGhsU7

Please let me know if there is missing configuration & step while trying to attempt your issue.

Regards,
Hans K.
Posted: February 11, 2014 1:46 AM
Hello,

I apologize for the late response.

Thank you very much for your code.

Please allow me to introduce one of WebCombo’s properties, “AllowAutoQueryHandler”.

The default value of this property is True, which the WebCombo will perform automatic query handling.
You need to set this property to False if you want to enable LoadOnDemand data retrieval mechanism. With this property set to False, the WebCombo will not perform the automatic (default behavior) query handling.
Data retrieval is handled at component level. The load-on-demand mechanism is also handled at component level, for instance, at WebCombo level.

For further information regarding “AllowAutoQueryHandler” property, please kindly have review on WebCombo documentation.


Regards,
Hans K.
Hello,

I apologize for the late response.

I try to make an unbound WebCombo page then add the row from an array.
I modify one of WebCombo solution samples, ‘AddUnboundRow.aspx’ page.
I create an array in ‘AddUnboundRow.aspx.cs’ page, named ‘employees’.
Then I add the array data to ‘WebCombo1’.

I uploaded the modified sample. Please kindly try to have review on the modified sample to see the result.
To get the sample, please try to follow this link: http://sdrv.ms/1bByGPm

To run the sample, you just simply add the file to the WebCombo Solution Samples.

Thank you.

Regards,
Hans K.

Hello,

Thank you for the reply & the information.

I will forward this issue to the developer team and I will let you know if there is an update as soon as possible.

We appreciate your patience in the meantime.

Regards,
Hans K.

Hello,

I apologize for any inconvenience this problem may have caused you.

Thank you for the question & snippet code.

Could you help me to provide more information regarding your issue?
Could you show me what error message & the result that you get in your local end? (for example, the screenshot).
So that I can help you further more.

Thank you.

Regards,
Hans K.

Hello,

I apologize for any inconvenience this problem may have caused you.

By default, the WebCombo in 2007 R1 release doesn’t designed for Internet Explorer 11 browser.
The latest WebCombo version in 2013 R1 release is already compatible with Internet Explorer 11 browser.

If you want to use WebCombo in Internet Explorer 11, I suggest you to update your current WebCombo to the latest version.

Thank you for your understanding.

Regards,
Hans K.

All times are GMT -5. The time now is 8:24 PM.
Previous Next