Guys
geezzz i cant get that simple thing to work!!
I got a text file and i want to extract specific information from it. I tried couple of different approach (texte file to table then table to string then string.find action.... and so on) but cant get that to work. Below is pasted a sample of the text file. What i want to do is each time i find a line that contains "LoginName = {" then i went to extract the line next to that one (ex: _vs = "ECON-APOGEEHALL\\SIEMENS\000") up to the end of the file. the goal will be to take all the extracted lines to populate a listbox. But if you can help me out with the first part of extracting the needed lines, i should be fine for the rest!
Thanks in advance for any help you can give me!
sample text file starts here:
-----------------------------------------------------------------------------------
%scopeNames = {
}
Origin = 1
FirstGraphicName = {
_vs = "H-HALL.DYN.HALL\000"
}
Initials = {
_vs = "srd\000"
}
Language = 1033
LoginName = {
_vs = "PHYSICAL_******\\srdube\000"
}
OperatorName = {
_vs = "Steve Ranger Dub\351\000"
}
Preference = 1
m_schedulerAccessSlidingWindow = 0
m_usePreferredAccessGroups = 0
m_supervisor = 0
FunctionalAccess = {
[0] {
DataType = 1
Level = 3
}
[1] {
DataType = 2
Level = 1
}
[2] {
DataType = 20
Level = 1
}
[3] {
DataType = 3
Level = 2
}
[4] {
DataType = 21
Level = 1
}
[5] {
DataType = 17
Level = 1
}
[6] {
DataType = 5
Level = 1
}
[7] {
DataType = 11
Level = 1
}
[8] {
DataType = 14
Level = 2
}
[9] {
DataType = 4
Level = 1
}
[10] {
DataType = 7
Level = 1
}
[11] {
DataType = 6
Level = 1
}
[12] {
DataType = 23
Level = 1
}
[13] {
DataType = 8
Level = 1
}
[14] {
DataType = 9
Level = 1
}
[15] {
DataType = 18
Level = 1
}
[16] {
DataType = 16
Level = 1
}
[17] {
DataType = 12
Level = 1
}
[18] {
DataType = 10
Level = 1
}
}
bi-assoc INSIGHT_ACCESS_CONFIGURE = {
#37-4-1-9
#37-4-1-11
}
}
#37-3-2-37 = {
%class = "*/ATOMInsightAccount%1"
%versioningMode = oocNoVers
%scopeNames = {
}
Origin = 1
FirstGraphicName = {
_vs = "H-HALL.DYN.HALL\000"
}
Initials = {
_vs = "SBTT\000"
}
Language = 1033
LoginName = {
_vs = "ECON-APOGEEHALL\\SIEMENS\000"
-------------------------------------------------------------------------------
geezzz i cant get that simple thing to work!!
I got a text file and i want to extract specific information from it. I tried couple of different approach (texte file to table then table to string then string.find action.... and so on) but cant get that to work. Below is pasted a sample of the text file. What i want to do is each time i find a line that contains "LoginName = {" then i went to extract the line next to that one (ex: _vs = "ECON-APOGEEHALL\\SIEMENS\000") up to the end of the file. the goal will be to take all the extracted lines to populate a listbox. But if you can help me out with the first part of extracting the needed lines, i should be fine for the rest!
Thanks in advance for any help you can give me!
sample text file starts here:
-----------------------------------------------------------------------------------
%scopeNames = {
}
Origin = 1
FirstGraphicName = {
_vs = "H-HALL.DYN.HALL\000"
}
Initials = {
_vs = "srd\000"
}
Language = 1033
LoginName = {
_vs = "PHYSICAL_******\\srdube\000"
}
OperatorName = {
_vs = "Steve Ranger Dub\351\000"
}
Preference = 1
m_schedulerAccessSlidingWindow = 0
m_usePreferredAccessGroups = 0
m_supervisor = 0
FunctionalAccess = {
[0] {
DataType = 1
Level = 3
}
[1] {
DataType = 2
Level = 1
}
[2] {
DataType = 20
Level = 1
}
[3] {
DataType = 3
Level = 2
}
[4] {
DataType = 21
Level = 1
}
[5] {
DataType = 17
Level = 1
}
[6] {
DataType = 5
Level = 1
}
[7] {
DataType = 11
Level = 1
}
[8] {
DataType = 14
Level = 2
}
[9] {
DataType = 4
Level = 1
}
[10] {
DataType = 7
Level = 1
}
[11] {
DataType = 6
Level = 1
}
[12] {
DataType = 23
Level = 1
}
[13] {
DataType = 8
Level = 1
}
[14] {
DataType = 9
Level = 1
}
[15] {
DataType = 18
Level = 1
}
[16] {
DataType = 16
Level = 1
}
[17] {
DataType = 12
Level = 1
}
[18] {
DataType = 10
Level = 1
}
}
bi-assoc INSIGHT_ACCESS_CONFIGURE = {
#37-4-1-9
#37-4-1-11
}
}
#37-3-2-37 = {
%class = "*/ATOMInsightAccount%1"
%versioningMode = oocNoVers
%scopeNames = {
}
Origin = 1
FirstGraphicName = {
_vs = "H-HALL.DYN.HALL\000"
}
Initials = {
_vs = "SBTT\000"
}
Language = 1033
LoginName = {
_vs = "ECON-APOGEEHALL\\SIEMENS\000"
-------------------------------------------------------------------------------
Comment