|
Try reading stderr as well as (or instead of) stdout.
|
|
|
|
|
Hi Bob,
I did try that and still received an empty output
|
|
|
|
|
I want divide the data of my datagrid in pages. For example I have 30 rows I would have 3 pages of 10 rows then have 2 buttons, one for "next page" and one for "previous page".
|
|
|
|
|
Im have little or no experience with WPF but this is something that I got from Googling
Paging in Datagrid WPF[^]
Every day, thousands of innocent plants are killed by vegetarians.
Help end the violence EAT BACON
|
|
|
|
|
Why? All that does is make it restrictive, and prevents the user from adjusting the view to their requirements. One of the major issues with Windows applications is that the user should be able to adjust the sizes to their own preference.
|
|
|
|
|
There are a few ways to accomplish this. The most obvious way is via using a CollectionView and filtering the pages based on their ordinals. This is pretty straightforward to do and shouldn't take you much work. An alternative approach would be to have a boolean visibility property on your data and use this to update the visibility of the data on the grid by using a BooleanToVisibilityConverter and collapsing the rows that shouldn't be visible. I've known people take this second approach because of a perceived performance impact with the CollectionView approach.
BTW - you should really have asked this in the WPF forum here on CP, rather than here.
|
|
|
|
|
Thanks for the answers but someone can write me the code?
|
|
|
|
|
You've been given the keywords to search on. If you use those keywords, there are numerous examples that show exactly how to do this on the web.
|
|
|
|
|
|
|
|
|
Collin Jasnoch wrote: You do not need to be snide about the code base existing in another forum an my seeking advice from this forum. Such correspondence only hurts this community.
I wouldn't say that Richard's response was "snide" or in any way hurt anyone - it was accurate and good advice. Perhaps you are being a little over-sensitive?
I don't know who you think downvoted you, or even why - there is no sign of a downvote on your original message - but I doubt if it was Richard.
Those who fail to learn history are doomed to repeat it. --- George Santayana (December 16, 1863 – September 26, 1952)
Those who fail to clear history are doomed to explain it. --- OriginalGriff (February 24, 1959 – ∞)
|
|
|
|
|
I don't recall downvoting this, but if I did it was a mistake for which I apologise. My original response to your question should have made my feeling clear enough - that questions such as this really belong on the forum associated with the product in question.
|
|
|
|
|
I should design a soft ware in C# that able to conver speech to the text (for the persian language) can any one guide me how can i do this?
|
|
|
|
|
|
|
|
Hello,
We have a web page dynamically loaded check boxes (depends on how many records in database).
What i need is to make sure the user checks only 5 check boxes. And if he checks the 6th one, give him a message that he can only check 5.
ASP:
Please select up to five:
<asp:Repeater runat="server" ID="rptCandidats" >
<ItemTemplate>
<div>
<asp:checkbox id="chResponse" runat="server" AutoPostBack="True" OnCheckedChanged="Check_Clicked"></asp:checkbox>
<%# Eval("ResText")%> <a href="<%#Eval("ResLink")%>" class="moreinfo"> More Info</a>
<asp:HiddenField ID="ResId" runat="server" Value ='<%#Eval("ResponId")%>' /> </div>
</ItemTemplate>
</asp:Repeater>
I tried to use OnCheckedChanged event, but it doesn't work.
Below is a C# code:
protected void Check_Clicked(Object sender, EventArgs e)
{
int checkedCount = 0;
foreach (RepeaterItem r in rptCandidats.Items)
{
CheckBox cb = (CheckBox)r.FindControl("chResponse");
if (cb.Checked)
{
checkedCount += (sender as CheckBox).Checked ? 1 : -1;
}
}
if (checkedCount > 5)
{
System.Web.HttpContext.Current.Response.Write("<SCRIPT LANGUAGE="JavaScript">alert(\"Only Up to five candidates can be selected.\")</SCRIPT>");
}
}
Any ideas how can i achieve it?
|
|
|
|
|
It's important in a question like this to know what "it doesn't work" actually means: please describe what the result (if any) of the count is, or describe any errors thrown when you execute the code.
Have you set a break-point, or added statements that write to some observable context, that allow you to watch what is happening with each enumeration of 'rptCandidats ?
My guess is that your count is off by one because you are adding in the value of the current 'chReponse (when you convert it from 'sender), as well as counting its value in the enumeration ... but, that's only a guess !
“The best hope is that one of these days the Ground will get disgusted enough just to walk away ~ leaving people with nothing more to stand ON than what they have so bloody well stood FOR up to now.” Kenneth Patchen, Poet
|
|
|
|
|
I made few changes and it is working now the way it suppose to.
protected void Check_Clicked(Object sender, EventArgs e)
{
string sysAlert="Only up to five selections.";
int checkedCount = 0;
foreach (RepeaterItem r in rptCandidats.Items)
{
CheckBox cb = (CheckBox)rptCandidats.Items[i].FindControl("chResponse");
if (cb.Checked)
{
checkedCount += (sender as CheckBox).Checked ? 1 : -1;
if (checkedCount > 5)
{
Page.ClientScript.RegisterStartupScript(this.GetType(), "myalert", "alert('" + sysAlert + "');", true);
cb.Checked = false;
}
}
}
But now when you click on the check box, the page blinks like it reloads .
|
|
|
|
|
Hi,
I am writing a client code for consuming the web service through a c# code by providing the end point URL through TLS authentication.
I need to send the request through TLS client authentication and am having the TLS certificate from the server which am sending the request for consuming the web service.
Can any help on how to use the TLS certificate using c# code for sending the rquest?
Many Thanks in Advance!!!
|
|
|
|
|
Dear All,
I am using Visual Studio 2010, C# and MySql.
In one of my Winforms, there is a bound DataGridView which contains few textbox columns. I am looking for a solution to add an ellipse button in one of the Textbox column, upon clicking the ellipse button it will show a second form. I've no experience of creating any user controls, so upon searching on net, I found plenty of examples but due to the lack of knowledge I am unable to follow them.
I am not looking for someone to spoon feed me, but some simple to advance tutorials/guidelines/sample will be highly appreciated.
Thanks in advance
Ahmed
|
|
|
|
|
|
I think he means ellipse button as in ... - not elliptical button
Everyone dies - but not everyone lives
|
|
|
|