|
Member 3374813 wrote: Please do not joke. I need it urgent
He isn't joking. If you want something you need to be polite. The word "urgent" is a sure way not to get help because it is rude and this is a voluntary forum. No one gets paid to post here. If you need help urgently then you can get paid for support that will answer your questions in a timely manner set out by the terms of service.
Man who stand on hill with mouth open wait long time for roast duck to drop in
|
|
|
|
|
Member 3374813 wrote: Please do not joke. I need it urgent
This site is not good for urgent queries. I'll recommend you rentacoder[^] for that!
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
It's no joke. I don't work for you, and presumably you won't be paying me, so why should I write your code for you? If your need is that great, consider hiring a codemonkey off rentacoder, and as far as the urgency goes, this doesn't even make it into my top 500 things to care about today list. It's only urgent to you - not me.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
After an extensive research period I would recommend using SQL queries somewhere
Between the idea
And the reality
Between the motion
And the act
Falls the Shadow
|
|
|
|
|
Yes I need esql Query. I am new to Entity framework. I need Entity SQL or LINQ Sql query for my problem
|
|
|
|
|
Member 3374813 wrote: I have three tables
So do I...
1. Coffee Table
2. Dinner Table
3. Bed-side Table
Member 3374813 wrote: I have following problems
My problem is singular...
1. You
Your problem is...
1. You are trying to do something you are incapable of doing (programming that is)
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
musefan wrote: 3. Bed-side Table
Do you mean night table
|
|
|
|
|
I mean a table you put at the side of your bed - Call it what you will
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
musefan wrote: I mean a table you put at the side of your bed - Call it what you will
Well why didn't you say so.
A Call it what you will Table.
Using the correct names for Controls/Classes, can make the difference between getting an answer and getting the bird!!
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Can anyone give advice on how to do this?
I am using a DeveloperExpress Grid linked to a BindingSource.
I import data into the bindingsource from a flat file then perform various checks to ensure the data is valid. If not, I set a column error for the row - as follows...
if (view.GetRowCellValue(intRow, "intX") == null || Convert.ToDouble(view.GetRowCellValue(intRow, "intX")) == (double)0.00)
{
dr.SetColumnError("intX", String.Format("{0}: Missing value.", view.Columns["intX"].Caption));
}
I have a button on the form to allow the user to filter the grid so that the grid will hide all valid rows to allow them to concentrate on fixing the invalid rows.
Can someone tell me how to apply a filter to the binding source to only show those rows with one or more column errors?
Many Thanks
|
|
|
|
|
Something like:
bindingSource1.Filter = "intX == null || intX == 0.00";
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Henry, Thanks for the reply.
I realise I can do that - the problem I have is that there is far more to the error checking than the small snippet I posted and it will not be feasible to do it this way. I could put in a dummy column and set the value to 1 within my error checking code on finding an error and filter on the dummy column = 1. However, I was hoping there was some way I could get a collection of the rows containing an error and use that to filter eg = extract all the ids of the rows with one or more errors into an array then convert that into a filter string... ID = id1 or ID = ID2...
|
|
|
|
|
Well in a .NET DataGridView you could iterate over the DataGridRowCollection and do that. I would assume the DevExpress version has the same functionality. Whether that is practical depends on the number of rows involved, from a time point of view.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Hi Henry - that's the approach I've now gone for...
string strFilterString = "";
sp00134BindingSource.Filter = ""; // Clear any Prior Filter //
foreach (DataRow dr in this.dataSet_AT.sp00134.Rows)
{
if (dr.HasErrors) strFilterString += " or ID = '" + dr["ID"].ToString() + "'" ?? String.Empty;
}
if (strFilterString.Length > 4) strFilterString = strFilterString.Remove(0, 4); // Remove initial " or " clause //
if (strFilterString == String.Empty) return;
try
{
sp00134BindingSource.Filter = strFilterString;
}
catch (Exception Ex)
{ .....
Thanks for the pointer.
|
|
|
|
|
Hi!
i am adding rows to a datagridView with two columns, all my rows will be displayed as a long list, instead I want it to for example when ten rows has been added I want the next row to be inserted side by side to the first one.
Thanks,
Mjelten
Edit:
to make it clearer:
1---------------- 10---------------------
2---------------- 11---------------------
3---------------- 12---------------------
this is the structure..
modified on Tuesday, June 2, 2009 8:25 AM
|
|
|
|
|
Add a new column after adding every 10 rows.
"Do first things first, and second things not at all."
— Peter Drucker.
|
|
|
|
|
that doesent work, beacuse I have tagged every row, with a variable..
|
|
|
|
|
The DataGridView is probably not the best control to use for this then. Consider something like a Repeater where you can specify the number of horizontal columns
only two letters away from being an asset
|
|
|
|
|
i thought that, but you do not think there is a way to get around it?
|
|
|
|
|
The way to get around it is to use the proper tools for the job.
only two letters away from being an asset
|
|
|
|
|
probably, but sometimes the time for doing the best solution is to long... i have to change a lot if I am going for a differnt dataholoder....
|
|
|
|
|
Depending on the layout of your form, and how you access the data, you could possibly make your own control, inheriting from DataGridView with the appropriate columns configured, and then create a new control every 6 (or whatever the number was) records. Complicated to keep track of though and could involve large numbers of controls.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
And how is adding time and complexity a solution?
only two letters away from being an asset
|
|
|
|
|
I didn't say it was optimal. Simply that it was an approach. Sometimes when you're stuck, even a wrong answer can prompt you into getting it.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Thanks, I have to think about that. I will probably go with changing the structure of my solution, because i am trying to use datagrudview in a way that it should not be used.
|
|
|
|