Page 1 of 2 12>
Topic Options
#91463 - 2003-02-14 08:27 PM KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I have two request for additions for my scripts at work.

They want to be able to type in a ListView object? I know it is supposed to be coming someday, but I don't think this is available yet or I don't know how.

They also want to Cut/Copy/Paste in the ListView object. I believe I can hack together some buttons to do this. I was wondering when ListView will have this built in.

I will post formal requests on the KixForms site if needed.

Thanks
_________________________
Kelly

Top
#91464 - 2003-02-16 04:00 PM Re: KixForms - Typing inside ListView
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
krabourn,

sitting here at home and actually tried to code some workaround for that with a TextBox (same size as selected Item) but its really ugly and a great pain ... so I give up [Big Grin]

In the mean time (until Shawn adds that feature to listviews) you can always steal some ideas from this sample : phone.kix

hth

Jochen
_________________________



Top
#91465 - 2003-02-16 04:44 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I agree with you. When Phone.kix came out I, almost immediatly used it as a spring board for another project. It has influenced other list base projects. Yeh, I know coding the function in is a pain. That is why I have not really done it yet.

Thanks for looking into it.
_________________________
Kelly

Top
#91466 - 2003-02-16 05:09 PM Re: KixForms - Typing inside ListView
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
krabourn, im currently looking into what is natively available with the ListView and what is not.

Q. You want to be able to edit ALL the items and subitems (like a spreadsheet?) or just the main item text (SubItem(0) ?)

Your right, I want to implement the ListGrid (spreadsheet-like) control but that wont be for a little-while (got TabControl and TabPage on the go right now).

Still investigating...

-Shawn

Top
#91467 - 2003-02-16 07:16 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
Right now, it would be just SubItem(0). But as soon as you add this and I let them edit the first item in the list, they will want to edit any field. So I guess that means make it like a spreadsheet.

Keep going with the Tabs. I am starting to rewrite my Frame crazy script to be more ready for Tabs.

Thanks for the hard work.
_________________________
Kelly

Top
#91468 - 2003-02-16 07:59 PM Re: KixForms - Typing inside ListView
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
Krabourn,

I nearly forgot that I did something similar once in a subform regarding Highscores (The script is not published yet because of some missing functionality in kixforms regarding ImageLists)

Just hacked together the parts so that it will work ...
The 3 columns there are a ListView (Data is stored in an ini file) as soon the actual score is below a HighScore for that specific level it lets you edit your name (A TextBox over the ListView SubItem) ... Maybe not exactly what you try but a start anyway ?


break on

$ini = @scriptdir + '\test.ini'
$moves = 45
$Pieces = 9

$HS = 50,Anonymus,100,Anonymus,150,Anonymus

    dim $highscore$frmWin$s$txt$pos$top
    Global $item0$item1$item2

    $frmWin                   = createobject("Kixtart.Form")
    $frmWin.Size              = 250,135
    $frmWin.Left              = $frm.CLientWidth /2 - $frmWin.ClientWidth /2
    $frmWin.Top               = $frm.CLientHeight/2 - $frmWin.ClientHeight/2

    $btnOK                    = $frmWin.Button("OK",$frmWin.ClientWidth/2+15,$frmWin.Clientheight-30,75,20)
    $btnOK.onclick            = "$$frmWin.Hide"

    $btnReset                 = $frmWin.Button("Reset Highscore",$frmWin.ClientWidth/2-90,$frmWin.Clientheight-30,90,20)
    $btnReset.onclick         = "ResetHighScores(1)"

    $lbl                      = $frmWin.Label("",140,5,100,15)
    $lbl.ForeColor            = KiXtart

    $lvw                      = $frmWin.ListView("",20,20,210,45)
    $lvw.enabled              = 0
    $lvw.View                 = 3
    $lvw.BorderStyle          = 0
    $lvw.HeaderStyle          = 0
    $lvw.BackColor            = $frmWin.BackColor
    $                         = $lvw.Columns.add("",75,1)
    $                         = $lvw.Columns.add("",45,1)
    $                         = $lvw.Columns.add("",90,0)
    $item0                    = $lvw.Items.Add("9 Pieces")
    $item1                    = $lvw.Items.Add("16 Pieces")
    $item2                    = $lvw.Items.Add("25 Pieces")

    for $i = 0 to 4 step 2
        $ = execute("$$item"+($i-$s)+".SubItems(1).Text = " + $HS[$i])
        $ = execute("$$item"+($i-$s)+".SubItems(2).Text = " + $HS[$i+1])
        $s = $s + 1
    next

    $highscore = CheckHighScore($moves,$Pieces)
    if $highscore
        $btnReset.Enabled = 0
        $frmWin.Caption   = "Highscore - $pieces Pieces"
        select
            case $Pieces = 9  $pos = 0 $top = 20 $HS[0] = $moves
            case $Pieces = 16 $pos = 1 $top = 35 $HS[2] = $moves
            case $Pieces = 25 $pos = 2 $top = 50 $HS[4] = $moves
        endselect
        $lbl.Caption         = "Enter your name ..."
        $txtName             = $frmWin.TextBox("",144,$top,100,18)
        $txtName.BorderStyle = 0
        $txtName.BackColor   = $frmWin.BackColor
        $txtName.OnLostFocus = "UpdateHighscores($$pieces)"
        $txtName.OnKeyDown   = "if $$txtName.KeyCode=13 UpdateHighscores($$pieces) endif"
        $ = execute("$$item$pos.SubItems(1).Text = $$moves")
        $ = execute("$$item$pos.SubItems(2).Text = ''")
        $txtName.SetFocus
    else
        $frmWin.Caption   = "Your Score : $moves moves"
        $btnOk.Default = 1
    endif

    $frmWin.Show
    while $frmWin.Visible
        $ = execute($frmWin.DoEvents)

function CheckHighScore($m,$p)
    select
        case $p = 9  and $m < $HS[0$CheckHighScore = 1
        case $p = 16 and $m < $HS[2$CheckHighScore = 1
        case $p = 25 and $m < $HS[4$CheckHighScore = 1
    endselect
endfunction

function UpdateHighscores($p)
    dim $o
    $txtName.Hide
    select
        case $p = 9  $HS[1] = $txtName.Text $item0.SubItems(2).Text = $HS[1]
        case $p = 16 $HS[3] = $txtName.Text $item1.SubItems(2).Text = $HS[3]
        case $p = 25 $HS[5] = $txtName.Text $item2.SubItems(2).Text = $HS[5]
    endselect
    $o = join($HS,',')
    $  = writeprofilestring($ini,'Global','HighScores',$o)
    $btnReset.Enabled = 1
    $btnOK.Default    = 1
    $lbl.Caption      = ""
endfunction

function ResetHighscores(optional $display)
    $   = writeprofilestring($ini,'Global','HighScores','50,Anonymus,100,Anonymus,150,Anonymus')
    $HS = split(readprofilestring($ini,'Global','HighScores'),',')
    for $i = 0 to ubound($HSif not $HS[$i$HS[$i] = "Anonymus" endif next
    if $display
        dim $s
        for $i = 0 to 4 step 2
            $ = execute("$$item"+($i-$s)+".SubItems(1).Text = " + $HS[$i])
            $ = execute("$$item"+($i-$s)+".SubItems(2).Text = " + $HS[$i+1])
            $s = $s + 1
        next
    endif
endfunction

_________________________



Top
#91469 - 2003-02-16 09:43 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I think I should share something, too. I share so often. That was sarcasm.

This is just a start a start of a generic DB/List editor. I am using it for adding/deleting/editing simple lists. This is my test script before I stick it into the real program. It supports my current needs, but I should add support for multiple columns.

http://www.geocities.com/krabourn@sbcglobal.net/

 -

 -



BREAK  ON

$ScriptDir = @CurDir
$iMargin = 5
$iLabelHeight = 15
$iButtonWidth = 86
$iButtonHeight = 30
$iButtonSmallWidth = 60
$iToolButtonWidth = 20
$iToolButtonHeight = 20
$FileRTAINI = $ScriptDir + '\RTA.INI'
$aSMSTSMID = Split (ReadProfileString ($FileRTAINI'SMS''SMSTSMID'), ',', -1)
$aSMSTSMName = Split (ReadProfileString ($FileRTAINI'SMS''SMSTSMNAME'), ',', -1)
;SMSTSMID=M5400634,M5400620,M5400621,M540061E,M540061F,M54005DE,M5400636,M5400635,M5400641,
;M5400637,M5400C85,M5400647,M5400638,M5400644,M5400643,M5400622,M54007F2,M54007F3
;SMSTSMNAME=SAN - BB4738,SAN - BC5691,SAN - CB8564,SAN - CM9626,SAN - CR8337,SAN - DG4893,
;SAN - DS2616,SAN - EI3473,SAN - JH1579,SAN - JW9976,SAN - KR8770,SAN - RE4271,SAN - RP8192,
;SAN - RR7523,SAN - PT7845/JJ8313/MG7423,SAN - UNKNOWN,SAN - ISDN/RAS,SAN - SELF SUPPORT

;--- DB form
$frmDB = CreateObject("Kixtart.Form")
$frmDB.ClientWidth = 300
$frmDB.ClientHeight = 300
$frmDB.FontSize = 8
$frmDB.BorderStyle = 0
$frmDB.Center
$frmDB.Rectangle(00$frmDB.ClientWidth$frmDB.ClientHeight)
$ilsicons = $frmDB.ImageList
$ilsicons.ImageSize = 16,16
$ilsicons.Images.AddStrip($ScriptDir + '\RTA.bmp', &00FF00FF1616)

$txtDBName = $frmDB.TextBox
$txtDBName.ToolTip = ''
$txtDBName.Location = $iMargin$iMargin
$txtDBName.Size = 225$iLabelHeight
$txtDBName.BorderStyle = 5
$txtDBName.OnChange='
    IF $$spnDBName.Visible = 0 AND $$txtDBName.Value <> ""
        $$btnDBAdd.Show
    ELSE
        $$btnDBAdd.Hide
    ENDIF'

$txtDBName.OnGotFocus = '$$btnDBDelete.Hide'

$spnDBName = $frmDB.SpinButton
$spnDBName.ToolTip = 'Which column to edit.'
$spnDBName.Location = $txtDBName.Right + $iMargin$txtDBName.Top
$spnDBName.Size = 15,25
$spnDBName.Orientation = 0
$spnDBName.BorderStyle = 0
$spnDBName.OnChange = '
    $$txtDBName.ToolTip = ""
    $$btnDBSave.ToolTip = "Save the Item back to the list."
    $$txtDBName.Text = $$lvwDB.Items($$lvwDBIndex).SubItems($$spnDBName.Value).Text
    $$txtDBName.SetFocus'

$spnDBName.Hide

$btnDBSave = $frmDB.ToolButton
$btnDBSave.ToolTip = 'Save the Item back to the list.'
$btnDBSave.Size = $iToolButtonWidth$iToolButtonHeight
$btnDBSave.Location = $spnDBName.Right$txtDBName.Top - 2
$btnDBSave.FlatStyle = 1
$btnDBSave.Alignment = 0
$btnDBSave.Icon = $ilsicons.Images(11)
$btnDBSave.OnClick = '
    IF $$spnDBName.Value = 0
        $$lvwDB.Tag = 0
        FOR $$Index = 0 TO $$lvwDB.Items.Count
            IF $$txtDBName.Text = $$lvwDB.Items($$Index).SubItems(0).Text
                $$Index = $$lvwDB.Items.Count + 1
                $$txtDBName.ToolTip = "DUPLICATE"
                $$btnDBSave.ToolTip = "DUPLICATE - Save the Item back to the list."
                $$lvwDB.Tag = 1
            ENDIF
        NEXT
        IF $$lvwDB.Tag = 0
            $$lvwDB.Items($$lvwDBIndex).SubItems($$spnDBName.Value).Text = $$txtDBName.Text
            $$txtDBName.ToolTip = ""
            $$btnDBSave.ToolTip = "Save the Item back to the list."
        ENDIF
        $$lvwDB.Tag = ""
    ELSE
        $$lvwDB.Items($$lvwDBIndex).SubItems($$spnDBName.Value).Text = $$txtDBName.Text
    ENDIF
    $$txtDBName.SetFocus'

$btnDBSave.Hide

$lvwDB = $frmDB.ListView
$lvwDB.ToolTip = 'Double Click an item to edit.'
$lvwDB.Location = $iMargin$txtDBName.Bottom + $iMargin
$lvwDB.Size = $frmDB.Width - (2 * $iMargin), $frmDB.Height - $lvwDB.Top - $iMargin
$lvwDB.GridLines = 1
$lvwDB.View = 3
$lvwDB.FullRowSelect = 1
$lvwDB.OnDoubleClick = '
    $$lvwDBIndex = $$lvwDB.FocusedItem.Index
    $$spnDBName.Value = $$spnDBName.Min
    $$txtDBName.Text = $$lvwDB.Items($$lvwDBIndex).SubItems($$spnDBName.Value).Text
    $$btnDBSave.Show
    $$spnDBName.Show
    $$txtDBName.SetFocus'

$lvwDB.OnClick = '
    $$lvwDBIndex = $$lvwDB.FocusedItem.Index $$txtDBName.Text = ""
    $$txtDBName.ToolTip = ""
    $$btnDBAdd.ToolTip = "Add to the list."
    $$btnDBSave.ToolTip = "Save the Item back to the list."
    $$btnDBSave.Hide
    $$spnDBName.Hide
    $$btnDBAdd.Hide
    $$btnDBDelete.Show'

$lvwDBIndex = ''

$btnDBAdd = $frmDB.ToolButton
$btnDBAdd.ToolTip = 'Add to the list.'
$btnDBAdd.Size = $iToolButtonWidth$iToolButtonHeight
$btnDBAdd.Location = $txtDBName.Right + $iMargin$txtDBName.Top - 2
$btnDBAdd.FlatStyle = 1
$btnDBAdd.Alignment = 0
$btnDBAdd.Icon = $ilsicons.Images(12)
$btnDBAdd.Hide
$btnDBAdd.OnClick = '
    IF $$txtDBName.Text <> ""
        $$lvwDB.Tag = 0
        FOR $$Index = 0 TO $$lvwDB.Items.Count
            IF $$txtDBName.Text = $$lvwDB.Items($$Index).SubItems(0).Text
                $$Index = $$lvwDB.Items.Count + 1
                $$txtDBName.ToolTip = "DUPLICATE"
                $$btnDBAdd.ToolTip = "DUPLICATE - Add to the list."
                $$lvwDB.Tag = 1
            ENDIF
        NEXT
        IF $$lvwDB.Tag = 0
            $$Item = $$lvwDB.Items.Add($$txtDBName.Text)
            $$lvwDB.EnsureVisible($$Item.Index)
            $$lvwDBIndex = $$Item.Index
            $$spnDBName.Value = $$spnDBName.Min
            $$txtDBName.Text = $$lvwDB.Items($$Item.Index).SubItems($$spnDBName.Value).Text
            $$txtDBName.ToolTip = ""
            $$btnDBAdd.ToolTip = "Add to the list."
            $$btnDBSave.Show
            $$spnDBName.Show
            $$txtDBName.SetFocus
        ENDIF
        $$lvwDB.Tag = ""
    ENDIF
    $$txtDBName.SetFocus'


$btnDBDelete = $frmDB.ToolButton
$btnDBDelete.ToolTip = 'Delete from the list.'
$btnDBDelete.Size = $iToolButtonWidth$iToolButtonHeight
$btnDBDelete.Location = $txtDBName.Right + $iMargin$txtDBName.Top - 2
$btnDBDelete.FlatStyle = 1
$btnDBDelete.Alignment = 0
$btnDBDelete.Icon = $ilsicons.Images(6)
$btnDBDelete.Hide
$btnDBDelete.OnClick = '
    IF Val($$lvwDBIndex) >= 0
        IF $$frmDB.MsgBox("Do you want to delete " + $$lvwDB.Items($$lvwDBIndex).SubItems(0).Text + "?", "Delete", 4) =&nbs p;6
            $$lvwDB.Items($$lvwDBIndex).Remove
        ENDIF
        $$txtDBName.SetFocus
    ENDIF'


$btnDBDone = $frmDB.ToolButton
$btnDBDone.ToolTip = 'Go back to the Main Window'
$btnDBDone.Size = $iToolButtonWidth$iToolButtonHeight
$btnDBDone.Location = $frmDB.Width - $btnDBDone.Width - $iMargin$txtDBName.Top - 2
$btnDBDone.FlatStyle = 1
$btnDBDone.Alignment = 0
$btnDBDone.Icon = $ilsicons.Images(5)
$btnDBDone.OnClick = '$$frmDB.Hide'
;--- DB form

$aSMSTSM = $aSMSTSMID,$aSMSTSMName
$aSMSTSMTitles = 'SMS TSM Collection IDs','SMS TSM Collection Names'
$aSMSTSM = fnDB($aSMSTSM$aSMSTSMTitles)
UBound($aSMSTSM)
FOR EACH $k IN $aSMSTSM
UBound($k)
    FOR EACH $r IN $k
        ? $r
    NEXT
NEXT
QUIT 0

FUNCTION fnDB($aDBListOPTIONAL $DBTitle)
    DIM $Index$Index2$DBTemp$ColumnIndex$ColumnName$Column
    FOR $ColumnIndex = 0 TO $lvwDB.Columns.Count - 1
        $lvwDB.Columns($ColumnIndex).Remove
    NEXT
    $lvwDB.Items.Clear
    IF UBound($aDBList[1]) > 0
        SELECT
            CASE UBound($DBTitle) > 0
               FOR EACH $ColumnName IN $DBTitle
                    $Nul = $lvwDB.Columns.Add($ColumnName,, 0)
                NEXT
            CASE $DBTitle <''
                FOR $Index = 0 TO UBound($aDBList)
                    IF $Index = 0
                        $Nul = $lvwDB.Columns.Add($DBTitle,, 0)
                    ELSE
                        $Nul = $lvwDB.Columns.Add($Index,, 0)
                    ENDIF
                NEXT
            CASE $DBTitle = ''
                FOR $Index = 0 TO UBound($aDBList)
                    $Nul = $lvwDB.Columns.Add($Index,, 0)
                NEXT
                $lvwDB.HeaderStyle = 0
        ENDSELECT
    ELSE
        SELECT
            CASE UBound($DBTitle) > 0
                $Nul = $lvwDB.Columns.Add($DBTitle[0],, 0)
            CASE $DBTitle <''
                $Nul = $lvwDB.Columns.Add($DBTitle,, 0)
            CASE $DBTitle = ''
                $Nul = $lvwDB.Columns.Add(0,, 0)
                $lvwDB.HeaderStyle = 0
        ENDSELECT
    ENDIF
    IF UBound($aDBList[1]) > 0
        $lvwDB.Items.Count = Val (UBound($aDBList[0]) + 1)
        FOR $Index = 0 TO Val(UBound($aDBList[$Index2]))
            FOR $Index2 = 0 TO Val(UBound($aDBList))
                $lvwDB.Items($Index).SubItems($Index2).Text = $aDBList[$Index2][$Index]
            NEXT
        NEXT
    ELSE
        $lvwDB.Items.Count = Val (UBound($aDBList) + 1)
        FOR $Index = 0 TO Val(UBound($aDBList))
            $lvwDB.Items($Index).SubItems(0).Text = $aDBList[$Index]
        NEXT
    ENDIF
    FOR EACH $Column IN $lvwDB.Columns
        $Column.Width = -1
        $Column.Width = -2
    NEXT
    $spnDBName.Min = 0
    $spnDBName.Max = $lvwDB.Columns.Count - 1

    $frmDB.Show
    $frmDB.SetFocus
    $txtDBName.SetFocus
    WHILE $frmDB.Visible
        $Nul = Execute($frmDB.DoEvents())
    LOOP
    DIM $aDBTemp [Val($lvwDB.Columns.Count - 1)]
    FOR $Index = 0 TO Val($lvwDB.Items.Count - 1)
        FOR $Index2 = 0 TO Val(UBound($aDBTemp))
            $aDBTemp[$Index2] = $aDBTemp[$Index2] + $lvwDB.Items($Index).SubItems($Index2).Text + ','
        NEXT
    NEXT
    FOR $Index = 0 TO Val(UBound($aDBTemp))
        $DBTemp = Substr($aDBTemp[$Index], 1Len($aDBTemp[$Index]) - 1)
        $aDBTemp[$Index] = Split($DBTemp',', -1)
    NEXT
    $fnDB = $aDBTemp
ENDFUNCTION



[ 18. February 2003, 03:27: Message edited by: krabourn ]
_________________________
Kelly

Top
#91470 - 2003-02-16 09:53 PM Re: KixForms - Typing inside ListView
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
hehe ... looks nice but misses the strip bitmap for the toolbuttons plus the contents of the ini [Big Grin]

{edit : But I got the picture what you doing here (thank to the ToolTips) hmmm ... a subform eh ?
not bad at all, I think it will be even more usable without editing directly ... One thing more : maybe you should enable/disable the delete button on Selection/nothing selected ? }

[ 16. February 2003, 21:57: Message edited by: jpols ]
_________________________



Top
#91471 - 2003-02-16 10:02 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
Bump...

I put my bitmap up there. It is mostly 16x16, 256 color ripped icons from WinXP.

I think the important thing is that you supply it an array and a title, optional, and it will spit the back out a string of values seperated by commas. I want to return an array, but I could not get that to work.
_________________________
Kelly

Top
#91472 - 2003-02-16 10:13 PM Re: KixForms - Typing inside ListView
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
two images up there ... both not visible ??
_________________________



Top
#91473 - 2003-02-16 10:18 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
Can you see these?
http://www.geocities.com/krabourn@sbcglobal.net/DBTemplate.bmp

http://www.geocities.com/krabourn@sbcglobal.net/RTA.bmp
_________________________
Kelly

Top
#91474 - 2003-02-16 10:20 PM Re: KixForms - Typing inside ListView
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
Gives an 'unavailable' message. Also, the standard image formats for webpages are .GIF, .JPG, and .PNG. Other formats like .BMP are not officially supported, however IE under Windows can display .BMP. You should rather go with the standard formats.

[ 16. February 2003, 22:21: Message edited by: sealeopard ]
_________________________
There are two types of vessels, submarines and targets.

Top
#91475 - 2003-02-16 10:56 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
sealeopard,

Doh! I should have remembered that. I changed them to gifs and they still don't work right.

Since the pictures don't show up for everyone, here is a link to my "do nothing" homepage.

http://www.geocities.com/krabourn@sbcglobal.net/
_________________________
Kelly

Top
#91476 - 2003-02-16 10:58 PM Re: KixForms - Typing inside ListView
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
GEOCITIES does not support Bitmaps using the .bmp extension. As Jens said, they will need to be either .JPG or .GIF

Internet Explorer supports .BMP, but the Webhost where you have your pasge is the one that does not support .BMP

Top
#91477 - 2003-02-16 11:01 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I have them as Gif. Do you see them now? I don't see them. I saw them as bmp.

I figured it out. When I converted the bmp to gif, The file extension created was GIF instead of gif.

[ 16. February 2003, 23:13: Message edited by: krabourn ]
_________________________
Kelly

Top
#91478 - 2003-02-16 11:20 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
Bump for the last time. The pictures should be fix now.
_________________________
Kelly

Top
#91479 - 2003-02-17 06:00 AM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I have been adding multi column support. I would like to be able to double click on a cell and know which cell that was, so I can edit it.

Is there a way to tell which item(x).subitem(y) was clicked or doubleclicked on?

code:
FUNCTION fnbtnEdit_Click()
IF $txtDBName.Text = ''
$txtDBName.Text = $lvwDB.FocusedItem.SubItems(0).Text
ELSE
$lvwDB.FocusedItem.SubItems(0).Text = $txtDBName.Text
$txtDBName.Text = ''
ENDIF
$txtDBName.SetFocus
ENDFUNCTION

_________________________
Kelly

Top
#91480 - 2003-02-17 08:24 AM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
I have reposted up above a newer version that can take multiple columns. I still need to fix editing value that are not in subitem(0). Also, all of the data arrays have to be the same size.
_________________________
Kelly

Top
#91481 - 2003-02-17 11:20 AM Re: KixForms - Typing inside ListView
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
krabourn,

maybe you should try a combination of .SelectedItems and FocusedItems

J.

[ 17. February 2003, 11:20: Message edited by: jpols ]
_________________________



Top
#91482 - 2003-02-17 03:06 PM Re: KixForms - Typing inside ListView
krabourn Offline
Hey THIS is FUN
*****

Registered: 2000-12-11
Posts: 244
Loc: San Antonio, Texas, USA
Unless you can show me as example, I don't see how to get passed subitem(0) without hard coding. [Confused]

I don't think you can select passed the first column.

[ 17. February 2003, 15:12: Message edited by: krabourn ]
_________________________
Kelly

Top
Page 1 of 2 12>


Moderator:  Shawn, ShaneEP, Ruud van Velsen, Arend_, Jochen, Radimus, Glenn Barnas, Allen, Mart 
Hop to:
Shout Box

Who's Online
2 registered (morganw, mole) and 414 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.174 seconds in which 0.144 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org