[C#] For Each ... menu

Shout-Out

User Tag List

Results 1 to 6 of 6
  1. #1
    omid's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    33
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [C#] For Each ...

    hey all i have a datagridview i want a code that i can use the values so ... i have 3 columns named X Position , Y Position and Z Position i want to get values for each rows and use them each like this

    Code:
                    WoW.WriteFloat(0xB9259C, x first cell value); 
                    WoW.WriteFloat(0xB925A0, y first cell value); 
                    WoW.WriteInt(0xB9252C, 4);
    and go on till the last cell value i need help anyone??

    [C#] For Each ...
  2. #2
    Mr.Zunz's Avatar Contributor
    Reputation
    92
    Join Date
    Mar 2007
    Posts
    393
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
    foreach( DataGridViewRow row in dgvCustomers.Rows)
    {
        // write row here
        WriteRow(row);
    }
    is this what your looking for?


  3. #3
    omid's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    33
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    no sorry(

    im looking for something to get Value from First Cell value from Column 1 named ( X Position ) and use it on

    Code:
                    WoW.WriteFloat(0xB9259C, First Cell of Column1);
    and get first cell of the second column named ( Y Position ) and use it on

    Code:
                    WoW.WriteFloat(0xB925A0, Column 2 First cell value);
    but not only first cell i want it do for ALL cells value

    like after first cell goes to seconds cells and do same and till end of datas

  4. #4
    Mr.Zunz's Avatar Contributor
    Reputation
    92
    Join Date
    Mar 2007
    Posts
    393
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
    /// <summary>
    /// Shows example usage of how to get the current cell.
    /// </summary>
    Code:
    void M()
    {
        //
        // Go from Y coordinate to a selected cell's value.
        // the Cells[1] part just takes the second cell for this example.
        //
        int yCoord = dataGridView1.CurrentCellAddress.Y; // You can get X if you need it.
        string Xcell = dataGridView1.Rows[yCoord].Cells[0].Value;
        string Ycell = dataGridView1.Rows[yCoord].Cells[1].Value;
        string Zcell = dataGridView1.Rows[yCoord].Cells[2].Value;
    }
    Think this is were your looking for


  5. #5
    omid's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    33
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    so hows the usage of this? is it like this?

    (this gonna be on a timer)
    Code:
                    WoW.WriteFloat(0xB9259C, Xcell); 
                    WoW.WriteFloat(0xB925A0, Ycell); 
                    (i dont need Z right now)
                    WoW.WriteInt(0xB9252C, 4);
    i think cells should go till last yes?

    edit :

    Code:
    int yCoord = dataGridView1.CurrentCellAddress.Y;
    is this only for Y position Column only? if yes why there is string Xcell and Zcell

  6. #6
    Danne206's Avatar Contributor
    Reputation
    183
    Join Date
    Jan 2008
    Posts
    717
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by omid View Post
    so hows the usage of this? is it like this?

    (this gonna be on a timer)
    Code:
                    WoW.WriteFloat(0xB9259C, Xcell); 
                    WoW.WriteFloat(0xB925A0, Ycell); 
                    (i dont need Z right now)
                    WoW.WriteInt(0xB9252C, 4);
    i think cells should go till last yes?

    edit :

    Code:
    int yCoord = dataGridView1.CurrentCellAddress.Y;
    is this only for Y position Column only? if yes why there is string Xcell and Zcell
    Please.. Re read his post again.
    Dahnniel [DOT] s [AT] gmail [DOT] com

Similar Threads

  1. /roar emote noises for each race.
    By Mizzypoo in forum World of Warcraft General
    Replies: 3
    Last Post: 03-01-2008, 11:46 AM
  2. How can i modify the starting place for each race ?
    By Wheeze201 in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 01-04-2008, 09:39 PM
  3. Starting stats for each race/class
    By Loveshock in forum World of Warcraft Guides
    Replies: 5
    Last Post: 11-11-2007, 06:49 AM
  4. farming/pvp music for each class (opinion)
    By Bludypeople in forum World of Warcraft General
    Replies: 15
    Last Post: 09-28-2007, 03:24 PM
All times are GMT -5. The time now is 08:18 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search