c# create html table test
string html = "<html><head><title>44444444</title>";
html += @"<style type='text/css'>
table {
border-collapse: collapse;
border: none;
width: 200px;
} td {
border: solid #000 1px;
}
</style>"; html+="</head><body>\r\n<table><tr style='color:#777;background: #eaeaea;'><td>aaaa</td><td>bbbb</td>"; if (exportOptionCtl1.checkBox1.IsChecked == true) {
html += "<td>" + exportOptionCtl1.checkBox1.Tag + "</td>";
}
if (exportOptionCtl1.checkBox2.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox2.Tag + "</td>";
}
if (exportOptionCtl1.checkBox3.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox3.Tag + "</td>";
}
if (exportOptionCtl1.checkBox4.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox4.Tag + "</td>";
}
if (exportOptionCtl1.checkBox5.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox5.Tag + "</td>";
} html += "</tr>"; for (int i = 0; i < 109; i++) { html += "<td>aaaaa" +i + "</td>";
html += "<td>bbbbb" + i + "</td>";
if (exportOptionCtl1.checkBox1.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox1.Tag + "</td>";
}
if (exportOptionCtl1.checkBox2.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox2.Tag + "</td>";
}
if (exportOptionCtl1.checkBox3.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox3.Tag + "</td>";
}
if (exportOptionCtl1.checkBox4.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox4.Tag + "</td>";
}
if (exportOptionCtl1.checkBox5.IsChecked == true)
{
html += "<td>" + exportOptionCtl1.checkBox5.Tag + "</td>";
}
html += "</tr>\r\n"; } html += "</table></body></html>"; StreamWriter w= File.CreateText("d:\\wx.html"); w.Write(html);
w.Flush();
w.Close();
<Grid x:Class="TestWpfApplication.ExportOptionCtl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="77" d:DesignWidth="417">
<Grid> <CheckBox Content="CheckBox1" Tag="ddd" Height="16" HorizontalAlignment="Left" Margin="6,6,0,0" Name="checkBox1" VerticalAlignment="Top" />
<CheckBox Content="CheckBox2" Tag="eee" Height="16" HorizontalAlignment="Left" Margin="91,6,0,0" Name="checkBox2" VerticalAlignment="Top" />
<CheckBox Content="CheckBox3" Tag="fff" Height="16" HorizontalAlignment="Left" Margin="167,6,0,0" Name="checkBox3" VerticalAlignment="Top" />
<CheckBox Content="CheckBox4" Tag="ggg" Height="16" HorizontalAlignment="Left" Margin="248,6,0,0" Name="checkBox4" VerticalAlignment="Top" />
<CheckBox Content="CheckBox5" Tag="hhh" Height="16" HorizontalAlignment="Left" Margin="6,37,0,0" Name="checkBox5" VerticalAlignment="Top" /> </Grid>
</Grid>
c# create html table test的更多相关文章
- when create a table,then show error ora-00952 tablespace tsb_1 not exist
		
QUESTION:When create a table,then show error ora-00952 tablespace tsb_1 not exist. STEP: 1.select us ...
 - IDEA的SonarLint插件报错Unable to create symbol table for
		
执行sonarLint 报错: Unable to create symbol table for ***File won't be refreshed because there were erro ...
 - SonarQube执行代码分析时,报错ERROR: Unable to create symbol table for : /**/*.java java.lang.IllegalArgumentException: Unsupported class file major version 55
		
若要转载本文,请务必声明出处:https://www.cnblogs.com/zhongyuanzhao000/p/11686633.html 起因: 最近正在尝试SonarQube的简单使用,但是当 ...
 - ORA-31633:unable to create master table "DP.SYS_EXPORT_FULL_11"  ORA-01658
		
问题描述:在进行数据泵进行数据库备份的时候,但是导出命令报错,环境是19C 4节点的rac 一体机.目前磁盘空间需要清理,清理之前先备份一下数据库 ORA-31626:job does not exi ...
 - DB2 create partitioned table
		
在Z上和开放平台上的创建方法还不太一样,两套人马开发出来的就是牛! 蛋疼…… 贴不同类型的几个例子感受一下,Z上的ASC,DESC不见了: CREATE TABLE foo(a INT) PARTIT ...
 - CMD Create Database & Table
		
Just do it: /* SQL 创建库 CREATE DATABASE jsp_demo DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; ...
 - MySQL中临时表的基本创建与使用教程(create temporary table )
		
当工作在非常大的表上时,你可能偶尔需要运行很多查询获得一个大量数据的小的子集,不是对整个表运行这些查询,而是让MySQL每次找出所需的少数记录,将记录选择到一个临时表可能更快些,然后在这些表运行查询. ...
 - sqlalchemy create single table
		
User.__table__.drop(engine) User.__table__.create(engine) https://stackoverflow.com/a/45287771/80250 ...
 - 【SQL篇章--CREATE TABLE】
		
[SQL篇章][SQL语句梳理 :--基于MySQL5.6][已梳理:CREATE TABLE][会坚持完善] SQL : 1. Data Definition Statements: 1.3 CRE ...
 
随机推荐
- B-树、B+树
			
B-树 用来在外部存储中组织数据. 严格来说,2-3树.2-3-4树都是B-树的特例:但B树更强调它的节点有很多个子节点,B-树中的节点可以有几十或几百个子节点. B-树也可以是查找树,也可以不是查找 ...
 - (网页)Http状态码大全(200、404、500等)(转CSDN)
			
当我们从客户端向服务器发送请求时 服务器向我们返回状态码 状态码就是告诉我们服务器响应的状态 通过它,我们就可以知道当前请求是成功了还是出现了什么问题 状态码是由3位数字和原因短语组成的(比如最常见的 ...
 - go 实现简单的加权分配
			
最近一段时间接手了一个golang编写的模块,从python转到golang这种静态语言还是有些不适应的,接手模块后的第一个需求是实现一个加权分配的方法. 简单来说数据库中存有3个链接,3个链接的权重 ...
 - Asp.Net WebApi Get请求整理(一)
			
Asp.Net WebApi+JQuery Ajax的Get请求整理 一.总结 1.Asp.Net WebApi默认不支持Get请求,需要在Action方法上指定[HttpGet], 除非Action ...
 - 重写EasyUI的$.fn.datagrid.defaults.editors
			
$.extend($.fn.datagrid.defaults.editors, { numberbox: { init: function (container, options) { var in ...
 - 6.1Python文件的操作(一)
			
目录 目录 前言 (一)基础类型 ==1.只读== ==2.只写== ==3.追加== (二)b二进制组合 ==1.读写二进制文件== (三)+ 附加组合 ==1.读附加== ==2.写附加== == ...
 - Linux 小知识翻译 - 「环境变量」
			
这次,谈谈关于「环境变量」的话题. 所谓变量,就是在程序中设置的,相当于在内存中准备的「一个用来存放数据的小箱子」. 即,程序通过变量来保存值,通过变量保存的内容来进行各式各样的计算处理. 「环境变量 ...
 - if 嵌套if 的先后顺序的区别 (自测)
			
# 验证 verify very good! # username = input("请输入用户名").capitalize()# password = input("请 ...
 - 百度、高德、谷歌、火星、wgs84(2000)地图坐标相互转换的JS实现
			
一.调用例子: <!DOCTYPE html> <html lang="en"> <head> <meta charset="U ...
 - 分布式服务化系统一致性(分布式事务、ACID、BASE、CAP)原理与解决方案
			
https://blog.csdn.net/rickiyeat/article/details/70224722