English
Forum

XProfan Editable Tabellenfelder

time again I ;)

 

Energizer
so people, login me for a long time too time again!

have now time everything something for me adjusted.
these now first the View source for scheduler, Save/loading as well as The Berechnung are others Schnipseln ;)
CompileMarkSeparation
Declare lvdll&,text$,x&,y&,z&,listview&
Def GetSysColor(1) !"USER32","GetSysColor"
var Font& = @CREATE("FONT","NEW TIMES ROMAN",14,0,0,0,0)
 $I Listview_Funktionen.inc
lvdll&=usedll("Listview.dll")
SetTrueColor 1
Window 400,400
Cls GetSysColor(15)
listview&=CreateListView(%hwnd,%hinstance,0,GetSysColor(24),-1,$31)
text$="Kurs,HJ1,HJ2,HJ3,HJ4,Endpunktzahl"
SetColumnsFromMem(listview&,addr(text$),0)
SetFont listview&,Font&
SetDialogFont Font&

Whileloop 1

    SetItem listview&,"Deutsch LK"
    SetItem listview&,"Mathematik LK"
    SetItem listview&,"Englisch LK"
    SetItem listview&,"LK 4"
    SetItem listview&,"LK 5"
    SetItem listview&,"GK1"
    SetItem listview&,"GK2"
    SetItem listview&,"GK3"
    SetItem listview&,"GK4"
    SetItem listview&,"GK5"
    SetItem listview&,"GK6"
    SetItem listview&,"Optional:"
    SetItem listview&,"ZusatzGK1"
    SetItem listview&,"ZusatzGK2"
    SetItem listview&,"ZusatzGK3"

EndWhile

SetColumnWidth(listview&,0,100)
SetColumnWidth(listview&,1,50)
SetColumnWidth(listview&,2,50)
SetColumnWidth(listview&,3,50)
SetColumnWidth(listview&,4,50)
SetColumnWidth(listview&,5,85)
ShowListView(listview&,10,48,354,270)
InitMessages(%hwnd)
usermessages $1407, 16

While 1

    waitinput
    Case %UMessage = 16 : BREAK
    'nach Doppellinksklick Item,

    If %umessage=$1407

        If Getfocus(Listview&)

            IF (&uwParam=1) OR (&uwParam=2) OR (&uwParam=3) OR (&uwParam=4)'hier nur 2.Spalte(Index =1) editieren

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

            Endif

        EndIf

    EndIf

Wend

messagebox("wird beendet","Programm",32)
CloseMessages(%hwnd)
freedll lvdll
lass=s4 href='./../../Function-References/XProfan/end/'>End

now have I several ask/Problems.

1. i'd gladly The row "optional" not editierfähig make, does it ?
tappt im dunkeln must indeed not absolutely there in the scheduler his, should hold only if someone Zusatzkurse chosen has possible his, these einzutragen!

2. should The scheduler to open the program possible entire in the Window To see his, so I do not scroll must.

2.1 is it possible, that the scheduler with enhance the Programmfensters too vergrößert?

3. after into Split 2-5 The notes registered get, need I a option, circa 42 FELDER with notes auszuwählen, which The Abiturnoten yield should.

3.1 particularly nice/helpful would it, if gewisse boxes already vordefiniert and not änderbar wären (z.B. Z.1-3, as well as Z. 6)
this would The verpflichtend einzubringenden notes mark, if someone these not knows.

Perhaps have your some ideas and suggestions for me ;)

LG and a lovely 1. Advent yet,
Peter
 
12/01/13  
 




Julian
Schmidt
Energizer (01.12.13)

1. i'd gladly The row "optional" not editierfähig make, does it ?
tappt im dunkeln must indeed not absolutely there in the scheduler his, should hold only if someone Zusatzkurse chosen has possible his, these einzutragen!


naturally does it, You must just prevent the it for this row The Edierfunktion aufruft, about so...
CompileMarkSeparation
Case &ulParam<>11 : EditManual(listview&,&uwParam, &ulParam,0)
>

Energizer (01.12.13)

2. should The scheduler to open the program possible entire in the Window To see his, so I do not scroll must.
2.1 is it possible, that the scheduler with enhance the Programmfensters too vergrößert?


the Skalieren of Listviews with the Fenstergröße is on the simplest over %WM_Paint lösbar. here time an example with a mehrzeiligen Edit box.
CompileMarkSeparation
CLS
Set("AutoPaint", 0)
Var edit&=Create("MultiEdit",%hwnd,"Ich bin skallierbar",10,10,width(%hwnd)-20,height(%hwnd)-20)

While 1

    WaitInput

    If %wmPaint

        SetWindowPos edit&=10,10 - width(%hwnd)-20,height(%hwnd)-20

    EndIf

Energizer  (01.12.13)

3. after into Split 2-5 The notes registered get, need I a option, circa 42 FELDER with notes auszuwählen, which The Abiturnoten yield should.


look you here To times the whileloop Loop on...

Energizer (01.12.13)

3.1 particularly nice/helpful would it, if gewisse boxes already vordefiniert and not änderbar wären (z.B. Z.1-3, as well as Z. 6)
this would The verpflichtend einzubringenden notes mark, if someone these not knows.


what want You very?

Greeting

Julian
 
XProfan X2
Win7 Professional, SP1, AMD FX(tm)-8350 Eight-Core Processor

˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗
Webseite [...] 
12/01/13  
 




Energizer
Bzgl. 1.)

I have mehrer versions ausprobiert, time is quite nothing happens, teils was of course The row optional not editierbar, for but the complete 1. slot and teils was only The first slot in line 11 (The in the "optional" standing) blocked, The decompose behind it but nevertheless editierbar.

Nochmal to that understanding: I have these scheduler. there should The complete first slot blocked his! Additional should ditto The GESAMTE row 11 (or. 12), means The with the Text "Optional" blocked go. is the practicable and if so, on which place must I since the row insert?

2.

does me sorrow but I have here at all no idea, How I the use should. I have attempts various. values or creep To take, having Fehlermeldungen and "nicht-More-beendbare" programs, but unfortunately no skalierte scheduler
have it not even hinbekommen The scheduler generally larger To make, that at least if I in the code one größeres "Window" einstelle, The scheduler there complete adjusted would

3.
alas Yes, whileloop, well there had I yourself on it come can. Sry there stood I simply on the Hose ... sometimes are it The simple items ;)

3.1
Folgendermaßen:
with of/ one Minimalbelegung all Fächer had one end the year 44 Semesternoten, from them the Endpunktzahl to charge would (11 courses * 4 school term) (naturally without Abiklausuren).

of it can but only 42 notes into Endpunktestand on the Abiturzeugnis yielded go, that is 2 notes entrapments lane (logischerweise dial one The schlechtesten). occupied one yet Zusatzkurse, has one yet More notes available, d.h. one can end too More code notes rausfallen let.

however there some Fächer, How z.B. The Abiturprüfungsfächer, The coercive into Endzensur yielded go must. Presumably knows however not everyone these verpflichtend einzubringenden courses.
moreover would it now very helpful, if under whom 42 auszuwählenden Semesternoten, already The markiert wären, The coercive yielded go must and these not changed (ausgeklickt) go can.

was this verständlich, otherwise mach I quick NEN Image or iwas circa it To explain?
 
12/03/13  
 




Thomas
Freier
Perhaps helps this example moreover:
CompileMarkSeparation
 $H windows.ph
 $I Listview_Funktionen.inc
var lvdll&=usedll("Listview.dll")
Cls
~SetClassLong(%hwnd, ~GCL_STYLE, (~GetClassLong(%hwnd, ~GCL_STYLE)- ~CS_HREDRAW - ~CS_VREDRAW))
Var bb& = Create("Button",%hwnd,"Ende",0,0,0,0)
var listview&=CreateListView(%hwnd,%hinstance,0,$FFFFFF,-1,$31)
InsertColumn listview&,"1",80,0
InsertColumn listview&,"2",80,0
InsertColumn listview&,"3",80,0
InsertColumn listview&,"4",80,0
InsertColumn listview&,"5",80,0
InsertColumn listview&,"6",80,0

Whileloop 10

    AddString(listview&,"Test|||||")

wend

var dlg&=%hwnd
Declare _dlgw&,_dlgh&, _odlgw&, _odlgh&, Ende%,bereich#,S&,Z&,y&
dim bereich#,320
_odlgw&=width(dlg&)
_odlgh&=height(dlg&)
setwindowpos bb&=(_odlgw&-70),5 - 60,20;0
ShowListView(listview&,10,30,(_odlgw&-20),(_odlgh&-40))
InitMessages(%hwnd)

WhileNot Ende%

    WaitInput
    case %key=4:Grid_do
    case Getfocus(bb&): Ende%=1
    y&=GetControlParas(bereich#)
    S&=Long(bereich#,4)'Spalte
    Z&=Long(bereich#,8)'Zeile

    If y&=2'rechter Mausknopf wurde gedrück

        Ifnot S&=1

            IfNot Z&=3

                EditManual(Listview&,S&,Z&,0)

            EndIf

        EndIf

    EndIf

Wend

proc Grid_do

    _dlgw&=width(dlg&)
    _dlgh&=height(dlg&)

    if ( ( _odlgw&<>_dlgw& ) or ( _odlgh&<>_dlgh& ) )

        _odlgw&=_dlgw&
        _odlgh&=_dlgh&
        setwindowpos bb&=(_odlgw&-70),5 - 60,20;0
        setwindowpos listview&=10,30 - (_odlgw&-20),(_odlgh&-40);0

    endif

endproc

dispose bereich#
CloseMessages(%hwnd)
='./../../Function-References/XProfan/freedll/'>freedll lvdll&
 
Gruß Thomas
Windows XP SP2, XProfan X2
12/03/13  
 




Thomas
Freier

2. should The scheduler to open the program possible entire in the Window To see his, so I do not scroll must.


there helps only to charge of Höhe and max. wide the Lines- or. Headertextes : [...] 
then whom Font (Höhe,ggf. tight) and the erforderliche Column determine and testing.
 
Gruß Thomas
Windows XP SP2, XProfan X2
12/03/13  
 




Energizer
many Thanks Thomas!

you have me very helped, have now already almost everything by me extended, another couple Lines but the can I too yet later make!

so wären trouble 1 and 2 resolved !

now should I only yet take off point 3 consider .
 
12/04/13  
 




Thomas
Freier
ex XProfan 11 take I The Gridboxfunktionen and if necessary from list view.dll. Lines pretending z.B.:
CompileMarkSeparation
AddString(listview&,"Deutsch LK|fest|fest|fest|fest")
AddString(listview&,"Mathematik LK|fest|fest|fest|fest")
AddString(listview&,"Englisch LK|fest|fest|fest|fest")
AddString(listview&,"LK 4")
AddString(listview&,"LK 5")
AddString(listview&,"GK1|fest|fest|fest|fest")
AddString(listview&,"GK2")
AddString(listview&,"GK3")
AddString(listview&,"GK4")
AddString( listview&,"GK5")
AddString(listview&,"GK6")
AddString(listview&,"Optional:")
AddString(listview&,"ZusatzGK1")
AddString(listview&,"ZusatzGK2")
AddString(listview&,"ZusatzGK3")

there presumably Zensuren, d.h., only numbers and Trenner association go should, müssten The Edit-boxes self created go. See example: Eigene_Eingaben. Weiterschalten by TAB is Perhaps not essential.
example for Edit with numbers: [...] 
or
CompileMarkSeparation
Def GetSysColor(1) !"USER32","GetSysColor"
cls GetSysColor(15)
UseFont "Arial",15,0,0,0,0
SETDIALOGFONT 1
CreateText(%hwnd,"num. input max.: nn.nn",30,120,200,22)
var Ed&=Create("Edit",%hwnd,"",30,165,80,20)
@sendmessage(Ed&,$00C5,3,0)'and on 3 to put (n.n) terminable
SetFocus(Ed&)

While 1

    WaitInput
    case %key=2 : BREAK
    case GETFOCUS(Ed&): NUMWERT Ed&,1'lever, characters before the comma

EndWhile

End

Proc NUMWERT' AUSWERTUNG on characters and to put

    Parameters ED.N&,ED.n%
    var a$="abcdefghijklmnopqrstuvwxyz"
    a$=a$+Upper $("abcdefghijklmnopqrstuvwxyz")
    a$=a$+"!§$%&/()=?''*':;,-_²³{[]}\^°<>|++-"
    var c$=""

    WhileLoop len(a$)

        c$ = MID$(a$,&Loop,1)' c$= the nte Stringteil
        Settext ED.N&,@Translate$(gettext$(ED.N&),c$,"")' unzulässige delete
        Settext ED.N&,@Translate$(gettext$(ED.N&),"..",".")' double delete

    EndWhile

    a$=trim$(gettext$(ED.N&))

    WhileLoop ED.n%+1

        @Match $("~.", a$)

        If (%MatchPos>0) AND (%MatchPos<ED.n%+1)

            a$=" "+a$' space or führende zero

        EndIf

    EndWhile

    If len(a$)=ED.n%

        case @IsKey(8):a$=left$(a$,len(a$))
        casenot @IsKey(8):a$=left$(a$,ED.n%)+"."

    EndIf

    SetText ED.N&,a$
    sendmessage(ED.N&,$00B1,len(gettext$(ED.N&)),-1)'Cursor ans end

ENDPROC

 
Gruß Thomas
Windows XP SP2, XProfan X2
12/04/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

6.399 Views

Untitledvor 0 min.
E.T.01/02/16
RICOSCH10/12/14
Georg Teles08/27/14
Andreas Koch08/15/14
More...

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