Click here to Skip to main content
15,894,330 members
Home / Discussions / C#
   

C#

 
GeneralRe: Arrow in rowheader Pin
anton-0910-Jul-08 22:42
anton-0910-Jul-08 22:42 
AnswerRe: Arrow in rowheader Pin
anton-0911-Jul-08 18:00
anton-0911-Jul-08 18:00 
QuestionTab Control Pin
half-life9-Jul-08 4:44
half-life9-Jul-08 4:44 
AnswerRe: Tab Control Pin
User 66589-Jul-08 4:49
User 66589-Jul-08 4:49 
QuestionHow to create ".eml" file using desktop application in .net to use it to send E-mail? Pin
shababnet9-Jul-08 4:29
shababnet9-Jul-08 4:29 
AnswerRe: How to create ".eml" file using desktop application in .net to use it to send E-mail? Pin
Christian Graus9-Jul-08 4:36
protectorChristian Graus9-Jul-08 4:36 
GeneralRe: How to create ".eml" file using desktop application in .net to use it to send E-mail? Pin
User 66589-Jul-08 4:39
User 66589-Jul-08 4:39 
Questionhashtable within a hashtable Pin
benjamin yap9-Jul-08 4:02
benjamin yap9-Jul-08 4:02 
Hi, i got a hashtable within a hashtable. How do i retrive the property from the inner hashtable

I got this orderTable which store a Order object.

Inside my Order object, i have a Hashtable itemList as a attributes. The itemList will store a product object which have the property ModelNumber

foreach (Order order in orderTable.Values)
{
    if (order.ItemList.ContainsKey(Convert.ToString(p.ModelNumber)))
    {
        uint modelNum = ((Product)order.ItemList[p.ModelNumber]).ModelNumber;
        string cellValue = Convert.ToString(p.ModelNumber);
        if (cellValue == Convert.ToString(modelNum))
        {
            dataGridProduct.Rows[currentRow].Cells["colSelect"].Value = true;
        }
    }
}


this is what i do, but i get

Object reference not set to an instance of an object.

on this line

uint modelNum = ((Product)order.ItemList[p.ModelNumber]).ModelNumber;

AnswerRe: hashtable within a hashtable Pin
Christian Graus9-Jul-08 4:07
protectorChristian Graus9-Jul-08 4:07 
GeneralRe: hashtable within a hashtable Pin
benjamin yap9-Jul-08 4:11
benjamin yap9-Jul-08 4:11 
GeneralRe: hashtable within a hashtable Pin
Christian Graus9-Jul-08 4:14
protectorChristian Graus9-Jul-08 4:14 
GeneralRe: hashtable within a hashtable Pin
User 66589-Jul-08 4:13
User 66589-Jul-08 4:13 
GeneralRe: hashtable within a hashtable Pin
Christian Graus9-Jul-08 4:15
protectorChristian Graus9-Jul-08 4:15 
AnswerRe: hashtable within a hashtable Pin
User 66589-Jul-08 4:10
User 66589-Jul-08 4:10 
GeneralRe: hashtable within a hashtable Pin
benjamin yap9-Jul-08 4:31
benjamin yap9-Jul-08 4:31 
QuestionWindows Service accessing DMZ resources Pin
newc19-Jul-08 3:46
newc19-Jul-08 3:46 
QuestionStop Timer Plz. Pin
Member 34356149-Jul-08 3:32
Member 34356149-Jul-08 3:32 
AnswerRe: Stop Timer Plz. Pin
stancrm9-Jul-08 3:54
stancrm9-Jul-08 3:54 
AnswerRe: Stop Timer Plz. Pin
Christian Graus9-Jul-08 3:56
protectorChristian Graus9-Jul-08 3:56 
AnswerRe: Stop Timer Plz. Pin
#realJSOP9-Jul-08 9:15
mve#realJSOP9-Jul-08 9:15 
Questionc# GUI for mapping two different databases Pin
sarmstrong039-Jul-08 3:05
sarmstrong039-Jul-08 3:05 
QuestionRedirecting to a new .aspx page Pin
WebMaster9-Jul-08 2:31
WebMaster9-Jul-08 2:31 
AnswerRe: Redirecting to a new .aspx page Pin
leppie9-Jul-08 2:37
leppie9-Jul-08 2:37 
AnswerRe: Redirecting to a new .aspx page Pin
ITS79-Jul-08 10:53
ITS79-Jul-08 10:53 
Questioniis pick up service Pin
shababnet9-Jul-08 2:26
shababnet9-Jul-08 2:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.