Quantcast
Channel: GSAK Forum
Viewing all articles
Browse latest Browse all 75560

CheckListBox needs list from System variable by lignumaqua - 2013-07-07

$
0
0
QUOTE (SensibleBob @ July 07, 2013 10:21 am)
QUOTE
Actually, the code doesn't need to be complicated. For example, the following code, if run before the form is displayed, will show the checkboxlist with the 1st, 3rd and 5th database selected:

Looks good, but if I want all checked except Default, it seems like I will need to loop through $DBs and build the Extract string based on the values. The total number of databases may change on each run, and it looks like the initial list is alphabetical.

Or maybe I can do a Replace of $DBs, just replacing "Default" with nothing, something like this?
CODE
$DBs=SysInfo("Databases")
$Form1 = editform($Form1,"DatabaseList","values",$DBs)
$DatabaseList=Replace("Default;","",$DBs)


(No access to GSAK right now, or I would just try it).

That would work sometimes! smile.gif it would fail if Default were the final database in the list as then there would be no semi-colon after it.

Viewing all articles
Browse latest Browse all 75560

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>