我可以知道为什么我的自定义listview适配器看起来像这样吗?
图片:
代码:
MainActivity.java
public class MainActivity extends AppCompatActivity {
CurrencyRatesDetails crd = new CurrencyRatesDetails();
TextView inputCurrTV, convertedAmtTV;
ListView currencyLV;
EditText inputAmtET;
ArrayAdapter<String> adapter;
String[] currNameArr = crd.getNames();
String[] currCodeArr = crd.getCodes();
String[] currRateArr = crd.getRates();
Context context;
int index = 0;
//String[] rateCurrArr = {"AUD", "BGN", "BRL", "CAD", "CHF", "CNY"};
//double[] rateArr = {0.944, 1.2824, 2.2842, 0.96158, 0.70946, 4.8624}
Menu myMenu = null;
double rate, amtInput, finalConversion;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
context = this;
inputAmtET …Run Code Online (Sandbox Code Playgroud) 直接.. 请问如何在图表底部创建自定义图例?
传说是..红色低床号
设计器中的代码:
<asp:Chart ID="ChartClass" Visible="false" runat="server" Height="500px" Width="720px">
<Series>
<asp:Series Name="SeriesAvailableClass" IsValueShownAsLabel="True" LabelAngle="-90" Font="Microsoft Sans Serif, 12pt" Legend="LegendClass" ChartArea="ChartAreaClass" ChartType="Column">
<SmartLabelStyle Enabled="false" />
</asp:Series>
<asp:Series Name="SeriesAllotedClass" IsValueShownAsLabel="True" LabelAngle="-90" Font="Microsoft Sans Serif, 12pt" Legend="LegendClass" ChartArea="ChartAreaClass" ChartType="Column">
<SmartLabelStyle Enabled="false"/>
</asp:Series>
</Series>
<ChartAreas>
<asp:ChartArea Name="ChartAreaClass">
<AxisX Title="Class">
<MajorGrid Enabled="false" />
</AxisX>
<AxisY Title="Number of Beds">
<MajorGrid Enabled="false" />
</AxisY>
</asp:ChartArea>
</ChartAreas>
<Legends>
<asp:Legend Docking="Bottom" Name="LegendClass"></asp:Legend>
</Legends>
<Titles>
<asp:Title Name="TitleChart" Font="Microsoft Sans Serif, 15pt, style=Bold" Text="Beds Statistics Summary (Class)" Alignment="TopCenter"></asp:Title> …Run Code Online (Sandbox Code Playgroud) 我在下面有一个方法可以count从一个名为的表中实际获取AuditActivity它,它需要今天的开始时间和今天的结束时间,分别是 00:00:00 和 23:59:59 以及另一个条件。一个datetime范围。
例如,今天的日期26/07/17,我想指定的where条件将DateTimeActivity采取count只当是between26/07/17 00:00:00和23:59:59 26/07/17。
我知道我编码的内容实际上是错误的,但我似乎无法正确完成。
我目前正在转换nvarchar为datetime哪个错误..
额外信息:datatype对于 DateTimeActivitydatetime在我的database
以及上面提到的字段值的示例:'26/07/2017 22:43:06'
//Wrong
//Get Number of Logins today from AuditActivity
public int countLoginsToday()
{
int count = 0;
StringBuilder sqlCmd = new StringBuilder();
sqlCmd.AppendLine("SELECT COUNT(*) FROM AuditActivity WHERE DateTimeActivity BETWEEN @getStartOfDay AND @getEndOfDay AND ActivityType = @getType");
//Date Today
String todayDate = DateTime.Now.Date.ToString();
//Time Start …Run Code Online (Sandbox Code Playgroud) 我试图得到一个DISTINCT列,FeedbackDT但我似乎无法弄清楚为什么它不起作用..
SQL查询:
SELECT COUNT(FeedbackID) as FeedbackID,
(SELECT DISTINCT CAST(feedbackDateTime AS DATE)) as FeedbackDT
FROM Feedback
WHERE feedBackDateTime <= GETDATE()
GROUP BY (feedbackDateTime)
Run Code Online (Sandbox Code Playgroud)
执行查询的结果
我搜索高低,但无济于事..
感谢任何帮助,谢谢..