Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
U

User 2254591

@User 2254591
About
Posts
8
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • How to get a specified number of records centered on a specific record in T-SQL
    U User 2254591

    Is is possible to write a query that would retrieve say the 20 records that are centered on a specifed record. In other words if I want orderId=9425 then I want the 5 orders for a particular customer that are less then 9425 and the 5 orders after 9425? I can't just say where orderID between 9420 and 9430 as these orders may not belong to this customer. This customers last order may have been orderID 8550 so would not show up in this query.

    Database database css sales tutorial question

  • How to tell what object is associate with context menu
    U User 2254591

    Yes I looked in the eventargs didn't see anything in there either. And I'm throwing up the context menu via right click. (Not sure if that is what your asking) But I solved the problem by using the Tag property as suggested earlier.

    C# question help tutorial

  • How to tell what object is associate with context menu
    U User 2254591

    Say I have two datagridviews (DG1, DG2) each with its own contextmenu, (Menu1,Menu2). Menu1 has menu items Save,Delete,Print and Menu2 has Save,Delete,Print now I would like to make one function that looks like private void Context_Menu_Save(object sender, EventArgs e){ DataGridView DG = (DataGridView)sender; } and then do what I need to do. The problem is that sender is the menuitem not the Datagridview that menuitem is associated with, so how do I find out which DataGridView's context menu was selected?

    C# question help tutorial

  • Adding Row Numbers to DataGridView
    U User 2254591

    An update to the problem. I took the code above and made a separte function out of it. Then Added the call to it after the GF.LoadDataGrid call with the same result. No numbers. Then I added a button to the form that called the same function. After the page was rendered and I clicked said button and the numbers appeared. So it seems that for some reason after the numbers are put there and the grid is rendered the row numbers disappear. Not sure why?

    .NET (Core and Framework) help question

  • Adding Row Numbers to DataGridView
    U User 2254591

    True I am trying to find out how many digits are in the number so I can make the row headers all the same length. So if there are 1-9 rows the headers would look like 1,2,3,etc... and when there are 10-99 rows then 01,02...99, and 100-999 then 001,002,003...999 and this part works fine. The problem is that the row numbers don't show up at all in the first datagrid and they show up just fine in the second datagrid, using the exact same code.

    .NET (Core and Framework) help question

  • Adding Row Numbers to DataGridView
    U User 2254591

    I have a function that loads data and configures the datagrid. I did this so that all the datagrids in the project would be the same. So I added a bit of code that is supposed to add row numbers to each of the datagrids.

    int numberofrows = DG.Rows.Count;
    int len = numberofrows.ToString().Length;
    string NumberForRow;
    for (x = 0; x < DG.Rows.Count; x++)
    {
    NumberForRow = Convert.ToString(x + 1);
    while (NumberForRow.Length < len)
    {
    NumberForRow = "0" + NumberForRow;
    }
    DG.Rows[x].HeaderCell.Value = NumberForRow;
    }

    This code is fired as so GF.LoadDataGrid(dgInvoices, DT, true,"InvoiceID,OrderID,Status,Date", "EVEN", ""); Where GF is GeneralFunctions class and LoadDataGrid is a method, the paramaters are dgInvoice is the DataGridView to load, DT is the DataTable, true/false is readonly, The first string is the Column headers, the second string is column spacing and the last string is columns that need to hidden if any. No the weird part. This line of code does not put in the Rowheader numbers. The DataGridView dgInvoices has an event tied to it that fills in another datagrid view with the detail of the invoice the call to fill that DataGridView is exactly the same GF.LoadDataGrid(dgInvoiceDetail,DT,true,"ItemID,Description,Qty,Amount","EVEN",""); and for that datagrid the number do appear. I know that there is no difference between the two datagrids as on the form, I have copied and pasted the first datagrid to make the second datagrid so they are the same. Not sure what is going on. Any help would be appreicated. Thank you.

    .NET (Core and Framework) help question

  • Tab Control Page Not Responding Fast Enough
    U User 2254591

    No not really, It does take some time for the CustomerInfo form to show up, and I assume that is because it does take time to load all the information on each of the tabs. But once the CustomerInfo form is displayed all the information should be loaded. So switching between tab pages should be quick. But it seems that the tabs are being reloaded everytime I switch over to them.

    .NET (Core and Framework) help performance question

  • Tab Control Page Not Responding Fast Enough
    U User 2254591

    I have a CustomerInfo form which is an Mdi form to the main form. The CustomerInfo form a has TabControl with 4 TabPages on it. From the Main form CustomerInfo CI = new CustomerInfo(); In the form constructor event i have the following pseudeocode LoadGeneralTab() LoadOrderTab() LoadInvoiceTab() LoadPayHistoryTab() Each of these functions loads several Datagrids with information. Then from the main form CI.MdiParent = this; CI.Show(); The CustomerInfo form shows up as expected and all is good. But when I click on the orderTab or invoiceTab or the payHistoryTab it takes a long time to switch over to it. And the speed of the switch seems to be the amount of information contained in the datagrid views. What I don't understand is why this is happening as it seems to me that all the grids have been populated with information in the constructor so what is taking so long to switch over. I have done this before and not had the same problem. And help would be appreciated.

    .NET (Core and Framework) help performance question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups