Solved

file management powerbuilder

Posted on 2011-09-07
6
467 Views
Last Modified: 2013-12-26
using FindFirstFileW we can search files  but how to search  file contains a word using  powerbuilder  .. any body having idea ?
0
Comment
Question by:digitecherp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 1

Accepted Solution

by:
carcarah earned 500 total points
ID: 36999524
First of all, we have to establish one thing here: Any function (internal or your function -- doesn't matter which) always have to load the list of files and read the name of each one.
So, I advise you to create a function working with a listbox to load the whole directory list and use the Pos ( string1, string2 {, start } ) to find the string.

String ls_filespec, ls_nm
Integer li_total, li_counter

ls_filespec = "*.*"
lb_files.DirList(ls_filespec, 0)
li_total = lb_files.totalitems()
FOR li_counter = 1 to li_total
      ls_nm = Mid(lb_arquivos.text(li_counter , 2, 3)
        if Pos ( ls_nm, "word you want") <> 0 then       ddlb_match.AddItem(ls_nm)
NEXT
0
 

Author Closing Comment

by:digitecherp
ID: 37505542
ok
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question