From a03fbfee3fdfd0383d7b8d571e20bdb8a50bd545 Mon Sep 17 00:00:00 2001 From: Sreemon Premkumar M Date: Mon, 18 Aug 2025 13:47:47 +0530 Subject: [PATCH 1/3] ES-975464 - Resolve the ReadMe file length issue in this sample repository --- README.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8e1cb2d..6005445 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,20 @@ # How to scroll and select the record programmatically in wpf and uwp treegrid? -This example illustrates how to scroll and select the record programmatically in wpf and uwp treegrid + +This example illustrates how to scroll and select the record programmatically in WPF TreeGrid and UWP TreeGrid. + +You can scroll to the record programmatically using the [ScrollInView](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.SfTreeGrid.html#Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_ScrollInView_Syncfusion_UI_Xaml_ScrollAxis_RowColumnIndex_) method by passing the row index of the record. You can get the row index of the record using the [ResolveToRowIndex](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.TreeGridIndexResolver.html#Syncfusion_UI_Xaml_TreeGrid_TreeGridIndexResolver_ResolveToRowIndex_Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_Syncfusion_UI_Xaml_TreeGrid_TreeNode_) extension method present in `Syncfusion.UI.Xaml.TreeGrid.Helpers`. + +You can select the record programmatically by setting the [SelectedItem](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Grid.SfGridBase.html#Syncfusion_UI_Xaml_Grid_SfGridBase_SelectedItem) property in `TreeGrid`. + +``` c# +private void Treegrid_Loaded(object sender, System.Windows.RoutedEventArgs e) +{ + var selectedItem = (this.treegrid.DataContext as ViewModel).SelectedItem; + var rowindex = this.treegrid.ResolveToRowIndex(selectedItem); + var columnindex = this.treegrid.ResolveToStartColumnIndex(); + //Make the row in to available on the view. + this.treegrid.ScrollInView(new RowColumnIndex(rowindex, columnindex)); + //Set the SelectedItem in SfTreeGrid. + this.treegrid.SelectedItem = selectedItem; +} +``` \ No newline at end of file From e183ad3fdad5f82b40786d4f201232d882c8ebe7 Mon Sep 17 00:00:00 2001 From: SyncfusionBuild <89958145+SyncfusionBuild@users.noreply.github.com> Date: Mon, 18 Aug 2025 14:54:29 +0530 Subject: [PATCH 2/3] Update gitleaks.yaml --- .github/workflows/gitleaks.yaml | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/.github/workflows/gitleaks.yaml b/.github/workflows/gitleaks.yaml index c115f77..f20f0ad 100644 --- a/.github/workflows/gitleaks.yaml +++ b/.github/workflows/gitleaks.yaml @@ -8,7 +8,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4.2.2 - name: Install the gitleaks run: wget https://github.com/zricethezav/gitleaks/releases/download/v8.15.2/gitleaks_8.15.2_linux_x64.tar.gz shell: pwsh @@ -21,18 +21,24 @@ jobs: continue-on-error: true - name: Setup NuGet.exe if: steps.gitleaks.outcome != 'success' - uses: nuget/setup-nuget@v1 + uses: nuget/setup-nuget@v2 with: nuget-version: latest - - name: Install the dotnet + - name: Install Mono if: steps.gitleaks.outcome != 'success' - uses: actions/setup-dotnet@v3 - with: - dotnet-version: '3.1.x' + run: | + sudo apt update + sudo apt install -y mono-complete + - name: Install the dotnet SDK to a custom directory + if: steps.gitleaks.outcome != 'success' + run: | + mkdir -p $GITHUB_WORKSPACE/dotnet + curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin --install-dir $GITHUB_WORKSPACE/dotnet --channel 6.0 - name: Install the report tool packages if: steps.gitleaks.outcome != 'success' run: | + export PATH=$GITHUB_WORKSPACE/dotnet:$PATH nuget install "Syncfusion.Email" -source ${{ secrets.NexusFeedLink }} -ExcludeVersion - dir $GITHUB_WORKSPACE/Syncfusion.Email/lib/netcoreapp3.1 - dotnet $GITHUB_WORKSPACE/Syncfusion.Email/lib/netcoreapp3.1/GitleaksReportMail.dll ${{ secrets.CITEAMCREDENTIALS }} "$GITHUB_REF_NAME" ${{ secrets.NETWORKCREDENTIALS }} ${{ secrets.NETWORKKEY }} "$GITHUB_WORKSPACE" ${{ secrets.ORGANIZATIONNAME }} - exit 1 \ No newline at end of file + dir $GITHUB_WORKSPACE/Syncfusion.Email/lib/net6.0 + dotnet $GITHUB_WORKSPACE/Syncfusion.Email/lib/net6.0/GitleaksReportMail.dll ${{ secrets.CITEAMCREDENTIALS }} "$GITHUB_REF_NAME" ${{ secrets.NETWORKCREDENTIALS }} ${{ secrets.NETWORKKEY }} "$GITHUB_WORKSPACE" ${{ secrets.ORGANIZATIONNAME }} + exit 1 From d9667e2743a30d4bceebbd0aa2108275a7ad2b53 Mon Sep 17 00:00:00 2001 From: SreemonPremkumarM Date: Thu, 23 Oct 2025 00:25:38 +0530 Subject: [PATCH 3/3] Update README.md --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 6005445..a770f06 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ -# How to scroll and select the record programmatically in wpf and uwp treegrid? +# How to Scroll and Select the Record Programmatically in WPF / UWP TreeGrid? -This example illustrates how to scroll and select the record programmatically in WPF TreeGrid and UWP TreeGrid. +This example illustrates how to scroll and select the record programmatically in [WPF TreeGrid](https://www.syncfusion.com/wpf-controls/treegrid) and [UWP TreeGrid](https://www.syncfusion.com/uwp-ui-controls/treegrid) (SfTreeGrid). -You can scroll to the record programmatically using the [ScrollInView](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.SfTreeGrid.html#Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_ScrollInView_Syncfusion_UI_Xaml_ScrollAxis_RowColumnIndex_) method by passing the row index of the record. You can get the row index of the record using the [ResolveToRowIndex](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.TreeGridIndexResolver.html#Syncfusion_UI_Xaml_TreeGrid_TreeGridIndexResolver_ResolveToRowIndex_Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_Syncfusion_UI_Xaml_TreeGrid_TreeNode_) extension method present in `Syncfusion.UI.Xaml.TreeGrid.Helpers`. +You can scroll to the record programmatically using the [ScrollInView](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.SfTreeGrid.html#Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_ScrollInView_Syncfusion_UI_Xaml_ScrollAxis_RowColumnIndex_) method by passing the row index of the record. You can get the row index of the record using the [ResolveToRowIndex](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.TreeGrid.TreeGridIndexResolver.html#Syncfusion_UI_Xaml_TreeGrid_TreeGridIndexResolver_ResolveToRowIndex_Syncfusion_UI_Xaml_TreeGrid_SfTreeGrid_Syncfusion_UI_Xaml_TreeGrid_TreeNode_) extension method present in **Syncfusion.UI.Xaml.TreeGrid.Helpers**. -You can select the record programmatically by setting the [SelectedItem](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Grid.SfGridBase.html#Syncfusion_UI_Xaml_Grid_SfGridBase_SelectedItem) property in `TreeGrid`. +You can select the record programmatically by setting the [SelectedItem](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Grid.SfGridBase.html#Syncfusion_UI_Xaml_Grid_SfGridBase_SelectedItem) property in TreeGrid. ``` c# private void Treegrid_Loaded(object sender, System.Windows.RoutedEventArgs e) @@ -17,4 +17,4 @@ private void Treegrid_Loaded(object sender, System.Windows.RoutedEventArgs e) //Set the SelectedItem in SfTreeGrid. this.treegrid.SelectedItem = selectedItem; } -``` \ No newline at end of file +```