<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[inaccessible]]></title><description><![CDATA[<p>Hallo nochmal!<br />
Habs jetzt erstmal soweit das es lief, aber jetzt bei der ausgabe kommt folgende Fehlermeldung:</p>
<p>&quot;char*Kran::Typ' is inaccessible within this content.&quot;<br />
Hab mal die Markierungen mit angegeben.(Habs mit einer # bzw. ## markiert.)</p>
<p>Ich weiß wirklich nicht weiter und habe auch nich so den plan vom programmieren, aber muss bis morgen einen wichtigen beleg abgeben.</p>
<p>danke im voraus<br />
gruß stuff</p>
<pre><code class="language-cpp">#include &lt;iostream&gt;
using namespace std;

class Bestand
      {      
             public:    long Nr;
                        char *Gst;
                        double Wert;
      };

class Kran
      {      
#             public: # char *Typ;         
                        char *Fa;
                        char *Leas;
                        double NKost;

                        Kran (char *Krantyp = &quot;AK-30&quot;,
                              char *Firma  = &quot;Allkran&quot;,
                              char *Leasing = &quot;ja&quot;,
                              double NebenKost = 50.7)

                              { 
                                     Typ = Krantyp;
                                     Fa  = Firma;
                                     Leas = Leasing;
                                     NKost = NebenKost;
                               };

                        ~Kran(){}
       };

class Verkauf : public Bestand, Kran
      {      
             public:   Verkauf (long nr = 1015,
                                char *Gegenstand = &quot;Autokran&quot;,
                                double wert = 132000,
                                char *Krantyp = &quot;AKX-35&quot;,
                                char *Firma = &quot;Werner&quot;)

                                {    Nr = nr;
                                     Gst = Gegenstand;
                                     Wert = wert;
                                     Typ = Krantyp;
                                     Fa = Firma;
                                 };

                        ~Verkauf(){}
                        double V_Preis();
      };

double Verkauf::V_Preis()
       {
             double VP;
             VP = (Wert + (Wert * NKost)/100)*0,16;
             return VP;
       };

class Sonderpreis : public Verkauf
      {      
             protected:    double Sond;

             public:       double SPr();

                           Sonderpreis (double sond = 12)
                                 {
                                       Sond = sond;
                                 };

                           ~Sonderpreis(){}
      };

double Sonderpreis::SPr()
       {
              double Preis;
              Preis = Verkauf::V_Preis();
              Preis = (1-(Sond/100))*Preis;
              return Preis;
       };

void main()
     {
           double P;

           class Sonderpreis SO1;
           SO1.Nr = 10024;
           SO1.Wert = 123000;
##     ##  SO1.Typ = &quot;AK-30&quot;;
           SO1.Fa = &quot;Allkran&quot;;
           SO1.NKost = 50.7;

           cout &lt;&lt; &quot;\n Nr.: &quot;          &lt;&lt; SO1.Nr;
           cout &lt;&lt; &quot;\n Gegenstand: &quot;   &lt;&lt; SO1.Gst;
           cout &lt;&lt; &quot;\n Wert: &quot;         &lt;&lt; SO1.Wert;
           cout &lt;&lt; &quot;\n Typ: &quot;          &lt;&lt; SO1.Typ;
           cout &lt;&lt; &quot;\n Firma: &quot;        &lt;&lt; SO1.Fa;
           cout &lt;&lt; &quot;\n Leasing: &quot;      &lt;&lt; SO1.Leas;
           cout &lt;&lt; &quot;\n Nebenkosten: &quot;  &lt;&lt; SO1.NKost;

           }
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/topic/136122/inaccessible</link><generator>RSS for Node</generator><lastBuildDate>Sat, 29 Aug 2026 07:14:13 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/136122.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 07 Feb 2006 14:23:51 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to inaccessible on Tue, 07 Feb 2006 14:23:51 GMT]]></title><description><![CDATA[<p>Hallo nochmal!<br />
Habs jetzt erstmal soweit das es lief, aber jetzt bei der ausgabe kommt folgende Fehlermeldung:</p>
<p>&quot;char*Kran::Typ' is inaccessible within this content.&quot;<br />
Hab mal die Markierungen mit angegeben.(Habs mit einer # bzw. ## markiert.)</p>
<p>Ich weiß wirklich nicht weiter und habe auch nich so den plan vom programmieren, aber muss bis morgen einen wichtigen beleg abgeben.</p>
<p>danke im voraus<br />
gruß stuff</p>
<pre><code class="language-cpp">#include &lt;iostream&gt;
using namespace std;

class Bestand
      {      
             public:    long Nr;
                        char *Gst;
                        double Wert;
      };

class Kran
      {      
#             public: # char *Typ;         
                        char *Fa;
                        char *Leas;
                        double NKost;

                        Kran (char *Krantyp = &quot;AK-30&quot;,
                              char *Firma  = &quot;Allkran&quot;,
                              char *Leasing = &quot;ja&quot;,
                              double NebenKost = 50.7)

                              { 
                                     Typ = Krantyp;
                                     Fa  = Firma;
                                     Leas = Leasing;
                                     NKost = NebenKost;
                               };

                        ~Kran(){}
       };

class Verkauf : public Bestand, Kran
      {      
             public:   Verkauf (long nr = 1015,
                                char *Gegenstand = &quot;Autokran&quot;,
                                double wert = 132000,
                                char *Krantyp = &quot;AKX-35&quot;,
                                char *Firma = &quot;Werner&quot;)

                                {    Nr = nr;
                                     Gst = Gegenstand;
                                     Wert = wert;
                                     Typ = Krantyp;
                                     Fa = Firma;
                                 };

                        ~Verkauf(){}
                        double V_Preis();
      };

double Verkauf::V_Preis()
       {
             double VP;
             VP = (Wert + (Wert * NKost)/100)*0,16;
             return VP;
       };

class Sonderpreis : public Verkauf
      {      
             protected:    double Sond;

             public:       double SPr();

                           Sonderpreis (double sond = 12)
                                 {
                                       Sond = sond;
                                 };

                           ~Sonderpreis(){}
      };

double Sonderpreis::SPr()
       {
              double Preis;
              Preis = Verkauf::V_Preis();
              Preis = (1-(Sond/100))*Preis;
              return Preis;
       };

void main()
     {
           double P;

           class Sonderpreis SO1;
           SO1.Nr = 10024;
           SO1.Wert = 123000;
##     ##  SO1.Typ = &quot;AK-30&quot;;
           SO1.Fa = &quot;Allkran&quot;;
           SO1.NKost = 50.7;

           cout &lt;&lt; &quot;\n Nr.: &quot;          &lt;&lt; SO1.Nr;
           cout &lt;&lt; &quot;\n Gegenstand: &quot;   &lt;&lt; SO1.Gst;
           cout &lt;&lt; &quot;\n Wert: &quot;         &lt;&lt; SO1.Wert;
           cout &lt;&lt; &quot;\n Typ: &quot;          &lt;&lt; SO1.Typ;
           cout &lt;&lt; &quot;\n Firma: &quot;        &lt;&lt; SO1.Fa;
           cout &lt;&lt; &quot;\n Leasing: &quot;      &lt;&lt; SO1.Leas;
           cout &lt;&lt; &quot;\n Nebenkosten: &quot;  &lt;&lt; SO1.NKost;

           }
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/988555</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/988555</guid><dc:creator><![CDATA[stuff]]></dc:creator><pubDate>Tue, 07 Feb 2006 14:23:51 GMT</pubDate></item><item><title><![CDATA[Reply to inaccessible on Tue, 07 Feb 2006 14:36:28 GMT]]></title><description><![CDATA[<p>stuff schrieb:</p>
<blockquote>
<p>&quot;char*Kran::Typ' is inaccessible within this content.&quot;</p>
<pre><code class="language-cpp">class Verkauf : public Bestand, Kran
</code></pre>
</blockquote>
<p>Du erbst, wenn du nichts anderes angibst, privat von Kran, d.h. alles was in Kran public war, ist in Verkauf privat. Lösung:</p>
<pre><code class="language-cpp">class Verkauf: public Bestand, public Kran
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/988570</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/988570</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Tue, 07 Feb 2006 14:36:28 GMT</pubDate></item><item><title><![CDATA[Reply to inaccessible on Tue, 07 Feb 2006 14:57:21 GMT]]></title><description><![CDATA[<p>vielen dank...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/988593</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/988593</guid><dc:creator><![CDATA[stuff]]></dc:creator><pubDate>Tue, 07 Feb 2006 14:57:21 GMT</pubDate></item></channel></rss>