English
Forum

Struct-items via variable define?

 
In Profan10 works Struct with Längenvariablen evident not:
CompileMarkSeparation
CLS
Declare Feld#[620], s1%,s2%,s$,i&
s1%=20
s2%=40
Struct Feld = Vorname$( s1% ), Nachname$( s2% )
Dim Feld#[],Feld
WaitInput
Dispose Feld#[]
a>

or mach I simply what wrong?
and does it Perhaps in Profan11?
 
09/07/08  
 




Jörg
Sellmeyer
functions in 11 neither. i think, with the Structures and classes is Roland not yet so far, as users. many things functions there not yet so so, How dwelt.
See z.B. here:  [...] 
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
09/07/08  
 



Help
$(n):n = length the Strings.


it standing of course not, that it itself hierbei circa a Constant deal must - but neither the it one argument his must.

writes one means
CompileMarkSeparationthen functions it.
 
09/07/08  
 



clear, the goes. But if I z.B. a File Edit wants, The I not yet know and its structure I first a Header read must, then can I STRUCT as commands in the momentum only forget. or can I with $(n) The Constant n yet somehow bearing? (Habs in the Interpreter with execute attempts, works but neither, because the in the momentum only single Befehlsstrings can).
greeting, woodpecker
 
09/07/08  
 



Nimm still Long instead of $(n) with the You you the lever GlobalAlloc(gPtr,sz) merkst, becomes too the structure small.
 
09/07/08  
 



and here The next Überraschung:
CompileMarkSeparation
 {$cleq}
Cls
Declare x%
set("decimals",0)
x% = 620
Declare Feld#[x%]
print "Das Bereichsarray wird ohne weiteres variabel dimensioniert"
Struct Subfelder = Hinz$(1), Kunz$(1)
Struct Feld = Vorname$(20), Nachname$(40), Subfelder
Dim Feld#[],Feld
print "Die Gesamtlänge der Struktur Feld wird korrekt berechnet: ",SizeOf(Feld#[0])
print
print "Nun folgen 4 Zuweisungen:"

With Feld#[1]

    .Vorname$="Quasimodo"
    .Nachname$="Pivonka"
    .Hinz$="A"
    .Kunz$="B"

EndWith

print "Die Ausgabe zeigt:"

With Feld#[1]

    print .Vorname$, "<-- Hier sollte Quasimodo stehen!"
    print .Nachname$, "<-- Hier sollte Pivonka stehen!"
    print .Hinz$, "<-- Hier sollte A stehen"
    print .Kunz$,"<-- Hier sollte B stehen"

EndWith

beep
print
print "Warum das bei A nicht klappt, ist denn doch etwas überraschend..."
WaitInput
Dispose Feld#[]
End
I faith, I need is a LONG-Drink...
 
09/07/08  
 




Jörg
Sellmeyer
What exactly works because there not? With me is


Quasimodo
Pivonka
A
B
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
09/07/08  
 



Hm so by me...

See 1. Ausgabewert

7 kB
Kurzbeschreibung: Wiederholbar?
Hochgeladen:09/07/08
Downloadcounter115
Download
 
09/07/08  
 




Sebastian
Sprenger
Hmm, means in XProfan 11 I get the same thing out How Jörg - So the right.

but in XProfan 10 Free is it objectively wrong!
The first spending is there not "Quasimodo", separate "A".

After of my Kurzrecherche is it well one bow at Vererben of Structures:  [...] 
 
Profan² 7.0e, XProfan 9, 11.2a, FreeProfan32
Windows Vista Home Premium 32-Bit, 2.8 Ghz, 4 GB RAM
Windows Me, 1.8 Ghz, 256 MB RAM
09/07/08  
 



Ah, one ray of hope... can itself means only yet circa months deal..
method to Versionsunterscheidung?
 
09/07/08  
 



Difference to that XProfan 10, 11 machts "korrekt".
 
09/07/08  
 




RGH
In XProfan 10 had to The To beerbende structure (in the Contrast to indicated in the Help) How with Objects on first place stand, otherwise funktionierte not correctly. In XProfan 11 is this Error fixed.

Greeting
Roland
 
Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4
09/07/08  
 



Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

4.210 Views

Untitledvor 0 min.
RudiB.08/16/22
Georg Teles12/27/18
Sebastian Sprenger10/13/13
Andre Rohland12/10/12

Themeninformationen



Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie