julmae Posted June 6, 2006 Share Posted June 6, 2006 mmh so im getting syntax error (illegal character) with this code and as far as I know there shouldnt be anything wrong with it $SettingList = GuiCtrlCreateListView(" Setting name | Status | Client status | Location | Restarts |", 10, 50, 490, 190) If FileExists("sro_restart.ini") Then $SettingName = IniReadSectionNames("sro_restart.ini") For $i = 1 To $SettingName[0] $SettingName[$i]=GUICtrlCreateListViewItem($SettingName[$i]|$RStatus|$CStatus|$Location|$Restarts|, $SettingList) Next Else Global $ListView $SettingName = "Example" WriteIni() $ListView = GUICtrlCreateListViewItem($SettingName|$RStatus|$CStatus|$Location|$Restarts|, $SettingList) EndIf error : ERROR: syntax error (illegal character) $SettingName = GUICtrlCreateListViewItem($SettingName[$i]| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ ERROR: syntax error (illegal character) $ListView = GUICtrlCreateListViewItem($SettingName| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ Anything obvious Iv missed in there ? Link to comment Share on other sites More sharing options...
Uten Posted June 6, 2006 Share Posted June 6, 2006 You GUICtrlCreateListViewItem items is supposed to be in one string. Somthing like this? $SettingList = GuiCtrlCreateListView(" Setting name | Status | Client status | Location | Restarts |", 10, 50, 490, 190) If FileExists("sro_restart.ini") Then $SettingName = IniReadSectionNames("sro_restart.ini") For $i = 1 To $SettingName[0] $SettingName[$i]=GUICtrlCreateListViewItem($SettingName[$i] & "|" & $RStatus &"|" & $CStatus & "|" & $Location & "|" & $Restarts, $SettingList) Next Else Global $ListView $SettingName = "Example" WriteIni() $ListView = GUICtrlCreateListViewItem($SettingName &"|" & $RStatus & "|" & $CStatus & "|" & $Location & "|" & $Restarts, $SettingList) EndIf Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
julmae Posted June 6, 2006 Author Share Posted June 6, 2006 yeah 8) thanks man Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now