ASCX页面标记:
# Sample data
y <- glm(mpg ~ wt, data = mtcars);
colName <- "wt";
# Print statement
print(paste0(
"The 95% confidence interval for covariate ",
colName,
" is ",
sprintf("[ %4.3f, %4.3f ]", confint(y, parm = colName)[1], confint(y, parm = colName)[2]),
" which means that we reject or fail to reject the null hypothesis that the coefficient of this covariate is zero "));
#[1] "The 95% confidence interval for covariate wt is [ -6.440, -4.249 ] which means that we reject or fail to reject the null hypothesis that the coefficient of this covariate is zero "
我的aspx
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="DateInput.ascx.cs" Inherits="CustomControls_DateInput" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajx" %>
<div class="input-group" style="width: 250px;">
<asp:TextBox ID="txb_dt1" runat="server" CssClass="form-control" ></asp:TextBox>
<span class="input-group-btn">
<asp:LinkButton ID="lb_caller" runat="server" CausesValidation="false" CssClass="btn btn-default btn-sm">
<span class="glyphicon glyphicon-calendar"></span>
</asp:LinkButton>
</span>
</div>
<ajx:CalendarExtender runat="server" ID="cal1" TargetControlID="txb_dt1" PopupButtonID="lb_caller" Format="MMM dd, yyyy"></ajx:CalendarExtender>
代码背后:
<asp:TemplateField HeaderText="Tanggal Kirim" SortExpression="tgl_kirim">
<InsertItemTemplate>
<uc1:DateInput ID="txbkirim" runat="server" Text_Width="0" Text='<%#Bind("tgl_kirim") %>' TextMode="SingleLine" CssClass="form-control"></uc1:DateInput>
</InsertItemTemplate>
</asp:TemplateField>
为什么它不起作用?
我想从ASCX页面访问id(&#34; cal1&#34;),怎么做?