当前位置:网站首页>WPF gets the control in the datagridtemplatecolumn of the specified row and column in the DataGrid
WPF gets the control in the datagridtemplatecolumn of the specified row and column in the DataGrid
2022-07-05 20:56:00 【ReflexMechanism】
/// <summary>
/// Get controls
/// </summary>
/// <param name="control_name"> Control name </param>
/// <param name="row"> That's ok </param>
/// <param name="col"> Column </param>
private void setStar(string control_name, int row, int col = 4)
{
DataGridTemplateColumn templeColumn = grd_fan.Columns[col] as DataGridTemplateColumn;
FrameworkElement s = grd_fan.Columns[col].GetCellContent(grd_fan.Items[row]);
Button tbOper = templeColumn.CellTemplate.FindName(control_name, s) as Button;
tbOper.Background = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#ffc400"));
}边栏推荐
- MySQL fully parses json/ arrays
- 国外LEAD美国简称对照表
- Material Design组件 - 使用BottomSheet展现扩展内容(二)
- Abnova丨 MaxPab 小鼠源多克隆抗体解决方案
- 2.<tag-哈希表, 字符串>补充: 剑指 Offer 50. 第一个只出现一次的字符 dbc
- Abnova丨荧光染料 620-M 链霉亲和素方案
- Duchefa丨低熔点琼脂糖 PPC中英文说明书
- Abnova丨 CD81单克隆抗体相关参数和应用
- Is Kai Niu 2980 useful? Is it safe to open an account
- LeetCode: Distinct Subsequences [115]
猜你喜欢

Écrire une interface basée sur flask

MySQL InnoDB架构原理

leetcode:1139. 最大的以 1 为边界的正方形

Who the final say whether the product is good or not? Sonar puts forward performance indicators for analysis to help you easily judge product performance and performance

示波器探头对信号源阻抗的影响

Phpstudy Xiaopi's MySQL Click to start and quickly flash back. It has been solved

How to make ERP inventory accounts of chemical enterprises more accurate

基于flask写一个接口

Duchefa d5124 md5a medium Chinese and English instructions

Maker education infiltrating the transformation of maker spirit and culture
随机推荐
ProSci LAG3抗体的化学性质和应用说明
Abnova maxpab mouse derived polyclonal antibody solution
When a user logs in, there is often a real-time drop-down box. For example, entering an email will @qq com,@163. com,@sohu. com
ClickHouse 复制粘贴多行sql语句报错
Go file path operation
Duchefa d5124 md5a medium Chinese and English instructions
Return to blowing marshland -- travel notes of zhailidong, founder of duanzhitang
Who the final say whether the product is good or not? Sonar puts forward performance indicators for analysis to help you easily judge product performance and performance
POJ 3414 pots (bfs+ clues)
珍爱网微服务底层框架演进从开源组件封装到自研
Abnova DNA marker high quality control test program
CLion配置visual studio(msvc)和JOM多核编译
Binary search
当Steam教育进入个性化信息技术课程
Popular science | does poor English affect the NPDP exam?
Abnova丨 MaxPab 小鼠源多克隆抗体解决方案
基于AVFoundation实现视频录制的两种方式
Promouvoir le développement de l'industrie culturelle et touristique par la recherche, l'apprentissage et l'enseignement pratique du tourisme
当用户登录,经常会有实时的下拉框,例如,输入邮箱,将会@qq.com,@163.com,@sohu.com
NPDP如何续证?操作指南来了!