隐藏的字段:
<input type="hidden" id="hidOrg1" runat="server" value="" />
<input type="hidden" id="hidBT" runat="server" value="" />
Run Code Online (Sandbox Code Playgroud)
javascript函数:
function doGetWave(obj) {
//debugger
var brk = document.getElementById('hidBT').value;
//var brkId = document.getElementById('hidBI').value;
var org = document.getElementById('hidOrg1').value;
session = obj.options[obj.selectedIndex].value;
sWaveText = obj.options[obj.selectedIndex].text;
if (brk == "") {
window.location.href = "url.aspx?multiple=" + org + "&wave=" + sWaveText + "&strORGId=multiple";
}
else {
window.location.href = "url.aspx?multiple=" + org + "&wave=" + sWaveText + "&BRKType=" + brk + "&strORGId=multiple";
}
}
Run Code Online (Sandbox Code Playgroud)
代码隐藏:
protected void Page_Load(object sender, EventArgs e)
{ …
Run Code Online (Sandbox Code Playgroud) 我正在尝试在sublime text 3构建系统中执行node-dev.node-dev在我的路径中:
然而,当我运行这个构建脚本时:
{
"cmd": ["node-dev", "$file"],
"selector": "*.js"
}
Run Code Online (Sandbox Code Playgroud)
我收到此错误,这也表明npm在我的路径中.
然而,当我使用节点而不是node-dev运行相同的构建脚本时,它执行得很好.
我还尝试将指向node-dev bin文件夹的"path"变量包含在内,这根本没用.
任何帮助,将不胜感激.谢谢.
我有两个列表:
List<L1>, List<L2>
L1 = { detailId = 5, fileName = "string 1" }{ detailId = 5, fileName = "string 2" }
L2 = { detailId = 5, fileName = "string 2" }{ detailId = 5, fileName = "string 3" }
Run Code Online (Sandbox Code Playgroud)
我希望将它们组合在一起,而不是重复:
List<L3>
L1 = { detailId = 5, fileName = "string 1" }{ detailId = 5, fileName = "string 2" }{ detailId = 5, fileName = "string 3" }
Run Code Online (Sandbox Code Playgroud)
我试过了:
L1.Union(L2).ToList();
L1.Concat(L2).Distinct().ToList();
Run Code Online (Sandbox Code Playgroud)
但两者都返回重复(1,2,3,3).
不知道我错过了什么.
编辑这是方法.它需要一个列表并从分隔的字符串创建另一个列表,并尝试将它们组合在一起.
private List<Files> CombineList(int …
Run Code Online (Sandbox Code Playgroud) 我有一个元素,我抓住了价值,因此:
var text = form1.elements[i].value;
Run Code Online (Sandbox Code Playgroud)
我想知道的是,如果我能以某种方式获取form1.elements [i] .value的ID.
我有一个方法,它将两个变量(一个int和一个分隔的字符串)发送到SQL Server proc.
变量值(从调试器复制):
detailId: 5
fileNames: "recruiter.txt|cert.pdf"
Run Code Online (Sandbox Code Playgroud)
方法:
public void InsertFiles(int detailId, string fileNames)
{
ConnectionStringSettings connString = ConfigurationManager.ConnectionStrings["PRADB"];
using (SqlConnection conn = new SqlConnection(connString.ToString()))
{
SqlCommand cmd = new SqlCommand();
cmd.Connection = conn;
cmd.CommandText = "dbo.InsertFiles";
cmd.Parameters.AddWithValue("@detailId", detailId);
cmd.Parameters.AddWithValue("@fileNames", fileNames);
try
{
conn.Open();
cmd.ExecuteNonQuery();
}
catch (Exception ex)
{
string exc = ex.ToString();
}
finally
{
conn.Close();
}
}
}
Run Code Online (Sandbox Code Playgroud)
这是proc:
ALTER PROCEDURE [dbo].[InsertFiles]
@detailId int,
@fileNames varchar(max)
AS
BEGIN
SET NOCOUNT ON;
insert into [dbo].[PRA_Files] (detailId, fileNames) …
Run Code Online (Sandbox Code Playgroud) select distinct
assignedTo,
alert_id,
insert_date_time,
alert_status_id,
alert_action_id,
alert_call_reason_id,
target_date
from Case_Management.AlertDetail
Run Code Online (Sandbox Code Playgroud)
工作良好.
select distinct
assignedTo,
alert_id,
max(insert_date_time),
alert_status_id,
alert_action_id,
alert_call_reason_id,
target_date
from Case_Management.AlertDetail
Run Code Online (Sandbox Code Playgroud)
返回错误列'Case_Management.AlertDetail.assignedTo'在选择列表中无效,因为它不包含在聚合函数或GROUP BY子句中.
我很难过.
asp.net ×3
c# ×3
javascript ×3
sql ×2
build ×1
list ×1
node.js ×1
runatserver ×1
sublimetext3 ×1