🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #4006

Re: Partial decision...

#4006
From: Sorokoletov Gregory
Date: Mon, 15 Apr 2002 06:25
56 lines
2422 bytes
Hi Jurko,

Thanks for your comments. You really are absolutely right in part of my
variable declaration :
But if you take the look at my next question "ADOMD: member properties
 again" you understand my problem.

Unfortunately your code also don't work, it generate error! (Access
violation)
You wrote:
{
    Properties* properties;
    Property* pr1;
    Variant propValue;

    properties =
        CellSet1->
            Axes->get_Item(1)->
            Positions->get_Item(0)->
            Members->get_Item(0)->
            Properties;
    pr1 = properties->get_Item(1); // This is the part that was missing! //
<- It will generate error!
    propValue = pr1->get_Value(); //<- It also will generate an error
}

It also will generate an error:
{
    Property* pr1;
    Variant propValue;

    pr1 = CellSet1->
            Axes->get_Item(1)->
            Positions->get_Item(0)->
            Members->get_Item(0)->
            Properties->get_Item(0);  // <- It works fine:
    propValue = pr1->get_Value(); //<- But it generates an error
}

But it will work fine:
{
    Variant propValue;

   propValue = CellSet1->
            Axes->get_Item(1)->
            Positions->get_Item(0)->
            Members->get_Item(0)->
            Properties->get_Item(0)->get_Value();  // it works fine
}

The Question is why using of temporally variable bring to error and how we
can decide this problem!


Thanks,
Sorokoletov Gregory
Technical Details
Message-ID: <3cba7252$1_1@dnews>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!newsfeed.online.be!skynet.be!skynet.be!newsfeed01.tsnz.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnews
References: <3cb5bd44$1_1@dnews> <3cb6b1c4_2@dnews> <dpn69a.c1g.ln@news.ve-mil.hr>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10698b,699ad39162d2b5f9
X-Google-Attributes: gid10698b,public
X-Google-ArrivalTime: 2002-04-14 23:31:40 PST
From: "Sorokoletov Gregory" <gsorokoletov@sovintel.net>
Newsgroups: borland.public.cppbuilder.database.ado
References: <3cb5bd44$1_1@dnews> <3cb6b1c4_2@dnews> <dpn69a.c1g.ln@news.ve-mil.hr>
Subject: Re: Partial decision...
Date: Mon, 15 Apr 2002 10:25:24 +0400
Lines: 58
Organization: Sovintel
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: 212.44.130.15
Message-ID: <3cba7252$1_1@dnews>
X-Trace: dnews 1018851922 212.44.130.15 (14 Apr 2002 23:25:22 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!newsfeed.online.be!skynet.be!skynet.be!newsfeed01.tsnz.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnews