English
Forum

XProfan Editable Tabellenfelder

 
- Page 1 -



Energizer
Hello dear shape ;),
be now too new thereby and on the work with XProfan 11.2 Free (this is still The latest or?)

have already a little bit herumgestöbert and dank Help of XLehrbuch of Dietmar horn already smaller ones programs geschafft.

now should I for a zwölfte class a Abiturrechner program. this should so functions, that one any Fächer inkl. spots types and the Abirechner anhand div. Vorgaben (Abiprüfungsfächer go 5-case gewertet, with electoral of/ one Zusatzprüfung 4-case etc.) The Endpunktzahl calculate.

now be I on the Überlegen, How to the with the input best regulate ought to.
on the dearest would me Yes really a scheduler (similar Excel) into the users simply yourself values eingebn can. Since I for directly nothing found have, wished I the whole a detour make, because the users in vordefinierten CheckBoxen its Fächer selecting and these then on The scheduler transfer go. is it thereby possible To define, How many Check boxes chosen go can?

Perhaps can someone of you with the Solution this Problems help, or. me even a yet better Solution for Implementierung the Userdaten in my Program suggest.

Mfg Peter
 
08/25/13  
 



 
- Page 1 -



Energizer
@Thomas suitor:
thanks for your speedy Help! your first Possibility gefällt me very well, there I will time something moreover rumprobieren ;)

@H.Brill:
too your Variant similar the Thomas, i think time there I will me what zusammenschustern ;)

1. Find the Variante Thomas because of the function to that "sperren" of/ one slot very well. with welchem commands I get here now a Vorgabetext into?
would have been me virtual there Vorgaben How "LK1" etc. reinzuschreiben ... for not so with know deliberated people ;)

Vielen Thanks people, your help one Beginner How me really very! ;)
 
09/26/13  
 




Thomas
Freier
About The functions list view.dll at lay out the Leerzeilen z.B.:
CompileMarkSeparation
Whileloop 5

    SetItem listview&,"","LK1",""

EndWhil

One Item with SetItemText(H,T,s,L) .
there XProfan 11.n is used, can also The functions to the Gridboxen uses go.
 
Gruß Thomas
Windows XP SP2, XProfan X2
09/26/13  
 




Energizer
ok means I have now a scheduler with several Split and zeilen, so How I me the whole wish ;) too with regulation into feldern.

now would I only gladly a single row and a single slot "schreibgeschützt" make

z.b. for slot 6 and row 12

PS: moreover would I gladly The scheduler larger make, so I any boxes at the same time see, find unfortunately only ne option around the window To enhance?

lg ;)
 
09/26/13  
 




Thomas
Freier
then scheidet The Variante 1 from. only over Variante 3 is the possible.
simply The terms inquire, z.B.:
CompileMarkSeparation
If %umessage=$1407

    IfNot (&uwParam=5) AND (&ulParam=11)'Doppellinksklick: edit Item

        EDIT &uwParam, &ulParam'Spaltenindex ,'Zeilenindex (nullbasierend)

    Endif

/a>

PS. Variante 2 goes naturally too, if no special EDITs uses go.
 
Gruß Thomas
Windows XP SP2, XProfan X2
09/26/13  
 




Energizer
well means Have now probiert, decompose/zeilen again drin udn so but How I get now mehrer zeilen or decompose "editierfähig" ?

Have now attempts in following row:
CompileMarkSeparation
IF &uwParam=1'hier nur 2.Spalte(Index =1) editierenre>

behind The 1 yet 2, 3 etc To write (with kommas for others decompose) has but
unfortunately not worked

How mach I the now? ;)
 
09/26/13  
 



 
- Page 2 -



Thomas
Freier
The request over
CompileMarkSeparation
IF (&uwParam=1) OR (&uwParam=2) OR (&uwParam=3)re>
or
CompileMarkSeparation
IF (&uwParam>0) AND (&uwParam<4)re>
or
CompileMarkSeparation
Minibeispiel List view-/Gridboxgröße to that Window
CompileMarkSeparation
Set("ErrorLevel", 2)
 $H windows.ph
 $H messages.ph
DECLARE LV&,a$

SubClassproc

    IF SUBCLASSMESSAGE(%HWND,~WM_SIZING) or SUBCLASSMESSAGE(%HWND,~WM_SIZE)

        SETWINDOWPOS LV&=10, 30 - (Width(%HWND)-20), (Height(%HWND)-60)
        SET("WinProc",0)

    ENDIF

endproc

CLS
~SetClassLong(%hwnd, ~GCL_STYLE, (~GetClassLong(%hwnd, ~GCL_STYLE)- ~CS_HREDRAW - ~CS_VREDRAW))
a$ = "Links;0;180;Mitte;2;100;Rechts;1;80"
LV&=Create("GridBox", %HWND, a$, 3, 10, 30, (Width(%HWND)-20), (Height(%HWND)-60))
SUBCLASS %HWND,1

WHILE 1

    WAITINPUT

ENDWHILE

END
 
Gruß Thomas
Windows XP SP2, XProfan X2
09/26/13  
 




Energizer
means for request found I your first Possibility best, has so far too worked still How mach I the for Lines?

and with the Listboxgröße komm I not yet integrally clear ...

After CLS catch You Yes on with setclasslong

ex the point was Yes your erstes Program quite different, there could I then any tables change and now standing Yes behind each spaltennamen two numbers and the boxes are none editierbar?

Yes sry I know is ne schwere birth with me here ;)
 
09/27/13  
 




Thomas
Freier
the was only an example with the internen Gridboxfunktion How the GridBOX of/ one Größenveränderung the Mainwindow anpasst.
circa Examples to that "Abiturrechner" anzupassen, müßten More Information exist, z.B.: should it one in the Size unveränderbares or veränderbares Mainwindow go. Erforderliche wide the Listbox , unless horizontal gescrollt go should. Wieviele Lines are vorgesehen. If the Mainwindow a Completed: Second/or Statuszeile?
 
Gruß Thomas
Windows XP SP2, XProfan X2
09/27/13  
 




Energizer
means the Mainwindow can quiet in its size veränderbar his, that would me alike and sometimes probably too very properly

How wide The listbox his should can I really not say, I The detailed wide white means would one accommodate to the window very well ... ought to not weg could I naturally too The longest combination of letters, numbers etc. The for fächer in question come enter and you ne pixelzahl or so name

zeilen are it 15, decompose 6

if You with toolbar supra The groin mean where File Save etc come should then Yes ;)

i'll soon each unterprogramme of my abirechners join and then here time NEN example post, vllt can your you then rather into displace.
 
09/27/13  
 




H.Brill
i know now not, whether ImportDLL already in the Version 11.2 Free
available was. if so, can The DLL too without Includedatei
(Listview_funktionen.inc) benefit. it are missing hold only The couple Procs,
The in the Include additional definiert are. but The can Yes
too in its Source copy.
the sähe then so from :
CompileMarkSeparation
Declare hd%, ende%, lvdll&, Grid&, edits$
Declare datensatz#
Declare sp1$, sp2$, sp3$, sp4$, Name$, Ort$, Strasse$, Telefon$
sp1$ = "Name"
sp2$ = "Wohnort"
sp3$ = "Strasse"
sp4$ = "Telefon"
Dim datensatz#, 20
lvdll& = Importdll("Listview.dll", "")
edits$ = "1111"' alle Spalten editierbar
hd% = @Create("Window",%HWnd,"Editieren mit rechter Maustaste",10,10,800, 300)
ende% = @Create("Button", hd%, "Ende", 20, 10, 120, 20)
Grid&=CreateListview(hd%,%hinstance,0,$ffffff,-1,$31)
' Spalten definieren
IColumn(Grid&, addr(sp1$), 220, 0)
IColumn(Grid&, addr(sp2$), 150, 0)
IColumn(Grid&, addr(sp3$), 150, 0)
IColumn(Grid&, addr(sp4$), 120, 0)
' zwei Einträge ins Listview
Name$    = "Maier"
Ort$     = "Hamburg"
Strasse$ = "Hauptstr"
Telefon$ = "4711"
Long datensatz#, 0  =  Addr(Name$)
Long datensatz#, 4  =  Addr(Ort$)
Long datensatz#, 8  =  Addr(Strasse$)
Long datensatz#, 12 =  Addr(Telefon$)
SItem(Grid&, datensatz#, 4)
Name$    = "Müller"
Ort$     = "Köln"
Strasse$ = "Rheinstr."
Telefon$ = "4712"
Long datensatz#, 0  =  Addr(Name$)
Long datensatz#, 4  =  Addr(Ort$)
Long datensatz#, 8  =  Addr(Strasse$)
Long datensatz#, 12 =  Addr(Telefon$)
SItem(Grid&, datensatz#, 4)
' Listview anzeigen u. Optionen (EnableEdits) setzen
ShowListview(Grid&, 10, 40, 600, 200)
InitMessages(hd%)' nötig wegen EnableEdits
EnableEdits(Grid&, 1+8)
SelectColumnEdits(Grid&, Addr(edits$))

WhileNot @Clicked(ende%)

    WaitInput

EndWhile

Dispose datensatz#
FreeDll lvdll&
/../function-references/XProfan/end/'>End
 
Benutze XPROFAN X3 + FREEPROFAN
Wir sind die XProfaner.
Sie werden von uns assimiliert.
Widerstand ist zwecklos!
Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.

Was die Borg können, können wir schon lange.
09/28/13  
 




Thomas
Freier

if You with toolbar supra The groin mean where File Save etc come should then Yes ;)

so How I it see reicht one Menu. The Button of/ one Toolbar are with umfangreichen Menüs for speedy Einklickaktionen of benefit.
an Statuszeile is suitable a chosen File/Information view, d.h., if after a Berechnug these stored and later again showing should.



with the Fächerauswahl would I these for DRAG&DROP offer.
example
CompileMarkSeparation
 $H Windows.ph
 $H messages.ph
 $I Listview_Funktionen.inc
Def GetSysColor(1) !"USER32","GetSysColor"
var Font& = @CREATE("FONT","NEW TIMES ROMAN",14,0,0,0,0)
Window 930,350
WindowTitle "Abiturrechner"
SetTrueColor 1
Cls GetSysColor(15)
SetDialogFont Font&
' Menü
PopUp "Programm"
AppendMenu 109,"Ende"
PopUp "Fächer"
AppendMenu 102,"übernehmen"
AppendMenu 103,"ausblenden"
AppendMenuBar 104,"Berechnen"
AppendMenuBar 105,"Drucken"
AppendMenuBar 106,"Eingaben löschen"
' Listview
Declare lvdll&,text$,x&,y&,z&,x%,y%,z%,listview&
lvdll&=usedll("Listview.dll")
listview&=CreateListView(%hwnd,%hinstance,0,GetSysColor(24),-1,$431)
'bei +400 kann der Anwender die Spaltenbreite nicht verändern
text$="Spalte 1,Spalte 2,Spalte 3,Spalte 4,Spalte 5,Spalte 6"
SetColumnsFromMem(listview&,addr(text$),0)
SetFont listview&,Font&

Whileloop 15

    SetItem listview&,str$(&loop),"","","","",""

EndWhile

SetColumnWidth(listview&,0,80)
SetColumnWidth(listview&,1,240)
SetColumnWidth(listview&,2,140)
SetColumnWidth(listview&,3,140)
SetColumnWidth(listview&,4,140)
SetColumnWidth(listview&,5,140)
ShowListView(listview&,10,10,900,270)
' damit beim Fensterverändern die Anzeige ruhiger bleibt:
~SetClassLong(%hwnd, ~GCL_STYLE, (~GetClassLong(%hwnd, ~GCL_STYLE)- ~CS_HREDRAW - ~CS_VREDRAW))
' Liste mit den Fächern
Declare Fach&, LV_F&
LV_F&=CreateListView(%hwnd,%hinstance,0,GetSysColor(24),-1,$431)
text$="Fach"
SetColumnsFromMem(LV_F&,addr(text$),0)
SetColumnWidth(LV_F&,0,80)
SetFont LV_F&,Font&
AddString(LV_F&,"Fach 1")
AddString(LV_F&,"Fach 2")
AddString(LV_F&,"Fach 3")
EnableDragDrop(listview&,1+16)
EnableDragDrop(LV_F&,1+16)

Proc FAECHEROPEN

    ShowListView(listview&,10,10,(Width(%HWND)-160),270)
    ShowListView(LV_F&,(Width(%HWND)-140),10,100,100)

EndProc

Proc FAECHERCLOSE

    ShowListView(LV_F&,0,0,0,0)
    ShowListView(listview&,10,10,(Width(%HWND)-20),270)

EndProc

' ermöglicht Aktionen beim Fensterverändern (durchbricht Waitinput)
SUBCLASS %HWND,1
InitMessages(%hwnd)
usermessages $1407, 16

While 1

    waitinput
    Case (%UMessage = 16) OR MenuItem(109) : BREAK

    If %umessage=$1407'nach Doppellinksklick

        If Getfocus(Listview&)

            IF (&uwParam=2) OR (&uwParam=3) OR (&uwParam=4)

                EditManual(listview&,&uwParam, &ulParam,0)'Spaltenindex, Zeilenindex (nullbasierend)

            Endif

        EndIf

    ElseIf MenuItem(102)

        FAECHEROPEN

    ElseIf MenuItem(103)

        FAECHERCLOSE

    ElseIf MenuItem(104)

        messagebox("berechnet was auch immer","Programm",32)

    ElseIf MenuItem(105)

        messagebox("druckt die Tabelle","Programm",32)

    ElseIf MenuItem(106)'leeres Listview

        DeleteAllItems(Listview&)

        Whileloop 15

            SetItem listview&,str$(&loop),"","","","",""

        EndWhile

        DeleteAllItems(LV_F&)
        AddString(LV_F&,"Fach 1")
        AddString(LV_F&,"Fach 2")
        AddString(LV_F&,"Fach 3")

    ElseIf MenuItem(15000)' Fenstergröße wurde verändet. Höhe soll bleiben

        x%=%WinLeft
        y%=%WinTop
        z%=Width(%HWND)+8
        SETWINDOWPOS %hwnd=x%,y% - z%,(270+80);0

    endif

Wend

messagebox("wird beendet","Programm",32)
CloseMessages(%hwnd)
freedll lvdll&
End

SubClassproc

    IF SUBCLASSMESSAGE(%HWND,~WM_SIZING) or SUBCLASSMESSAGE(%HWND,~WM_SIZE)

        case ~WM_LBUTTONUP: SetMenuItem 15000' für Aktionen nach der Fenstergrößenänderung
        SETWINDOWPOS Listview&=10, 10 - (Width(%HWND)-22), 270
        SET("WinProc",0)

   
ass=s4 href='./../../function-references/XProfan/endif/'>ENDIF endproc

should DROP only after a slot the Hauptliste permitted his, must this over GetDragDropParas(B) gesteuert go. too, if in the Fächertabelle The factors to the Fächern hinterlegt are and these in the Hauptliste übernommen go should.

19 kB
Hochgeladen:09/28/13
Downloadcounter153
Download
 
Gruß Thomas
Windows XP SP2, XProfan X2
09/28/13  
 




Energizer
so first thanks for eure Help!

be now first To 10.10 in the leave, will be me then again with you report

lg ;)
 
09/28/13  
 




Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

13.037 Views

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