How To Sort Columns In List View -- Just Like Windows Explorer
Hi,I am using ListView Control.. I want to sort the listview on a particular column when user selects it. Is there any direct way of doing this.. And can I set colors to rows in a Listview control.. Like I have a situation where I want alternate colours to be displayed.. Is it possibleRegardsSurya Prakash
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Windows File Explorer.. Icon View And List View.
I'm trying to duplicate a function of the explorer.. The folder contents view.
See example of what I mean...
http://www.ibarn.net/fun/files/thumblist.jpg
I can do everything I need using the filelistbox with the sole exception of changing the display style. I don't want a file list, I want a list-view or icon-view. (Preferably both, with the option to switch between them.)
So my question to you fine people is...... what API or component could I find this capacity in? I've looked at all of the components and didn't see anything that looked close, and a search on the subject yeilds hundreds of people trying to emulate the "filemanager" explorer style, but none trying to kick out a normal, boring icon view like this.
Any help would be greatly appreciated.
Thanks.
Windows Explorer Context Menu In A List View
I have a listview populated with filenames
How can I display the standard Windows Explorer context menu when I right click on an item?
I'm sure I've done this before but can't find the code
2 Columns In List View:
i ahve a list view box, when i click the add button, i need to be able to add:
add.text in the first column
desc.text in the second column
but i can only get add.text in the first column.......
List View Sort
i have hundred and one solutions for listview sorting.. but non works for dates sort... why is it can any one explain...
there is some thing MS has to say abt it but that works very slow... does any one has a better one...
MS Listview
a simple one is dates sort in listview format of date is DDMMYYY HH:MM:SS
10xs
Sort List View
How can i make a list view that when users click the header will sort the list by the header? (like in windows explorer)
Also, users can rename my subitem. How can i do to disable them from it?
List View --> Sort
How can I sort list view according to integer or date format and not according to string ?
Sort In A List View
Hi vb-world:
I have problem with a list view in mode Report, my first column is numeric and consecutive, and when I use the sort property the numbers shows like this, "1,10,11,12... 2,20,21... etc", How can I order or what need to do to the list view order this column consecutively?
Thanks a lot in advance.
Regards.
Windows Explorer View
Hi Everyone,
I was wondering if there is a way to make a tree view hierarchy of my local file system that looks like the hierarchy in Windows Explorer XP.
If so, is there a way to double click a certain file or folder in this tree view and move that directory address to a listbox? Thank you all in advance. These forums look awesome and I'm looking forward to learning and helping everyone. THANKS!
Windows Explorer View
Hello, I need to have a tree view that is populated with the current drives, directories, and files that are on the computer where the program is ran.
Is there an easy way to do this? I basically want it to work like the old File Manager worked.
Thanks
Ordering Columns In A List View
I know I can use the ascending and descending properties to order the first column in a list view, but how can I order the other columns as well?
Listview Columns In List View
I am trying to use Listview to import data from an Access table and I only want to use the list view not the list report. The data imports OK and populates the list OK into (in this case with the quantity of data imported) 4 columns.
Trouble is, all the data is truncated and I can find no way of setting the column widths as you can in the normal list box. I do not have any sub-items, just a single list so I do not need to set up any column headers.
Tree View Like Windows Explorer?
I must make a tree view application look like Windows Explorer where all contents are entered at runtime and items can be named when and where a node is inserted, like Explorer. Is there an example out there that mimics the features of Explorer? Thanks.
Program: Set Explorer Windows To Same View
I am trying to think of a way of creating a basic program with a button.. when clicked it will set my Windows explorer windows to display in the same view each time.
i.e. -
- From the View menu, click Folder Options.
- Click the View tab.
- Click Like Current Folder, click Yes to confirm, and click OK.
Does anyone have any ideas as to how I could code this? Or has anyone got any examples to share?
Thanks in advance for any help
S
Windows-explorer Directory View
Hi,
which component do I have to integrate, if I want to use a view like in the leftend side of the windows-explorer.
it is also used in winzip (where you choose the directory to save the extracted files).
Look at the attached file explorer.jpg
Thanks
Thomas
List View Select - Multiple Columns
I have a listview control with two columns...
1. File Name
2. Extension
When I selected the file I return the file name, but if i want to retrieve the properties regarding the file i need the extension which is in column 2...
This will get the information in column 1 (File Name)
Set objFile = objFSO.GetFile(DirList.List(DirList.ListIndex) & "" & lstFileList.SelectedItem.Text)
How do I get it so that it gets the info in column 1 and adds the info of column 2 to that string? i.e.
file name extension
mydoc doc
myvideo avi
myemail eml
i want it so that when i click on mydoc the string becomes... mydoc.doc, any ideas? thanks
- gabe
How Do I Hide/unhide Columns In A List View?
I want the user to choose the columns for a specified output though all the columns will be filled
with data , i want to display only those columns which the user selects.Currently i make the width
of the hidden column as - 0 but that the user can just keep his mouse on the header and drag to
see the hidden column. How do I actually hide it???
Sorting On DATE Columns In MS List View
Does anybody know how to get this to work?
The listview seems only capable of accepting strings as it's items so dates have to be converted to text and therefore are sorted as text.
How can I get around this?
Freeze The Columns Of List View Control
Hi Gurus,
I want to freeze the columns of a Listview control in Report view mode. Is there any property of List View or any other code example to show me how to prevent the columns to be resized by the user?
Help me plz, it is really necessary.
Waqas...
How To Auomatically Sort Items In A List View???
Hai my friends,
I have a question to ask. In the list view, it shows the headers as Name, Price, Quantity, RemainingQuantity. Now, all I need to know is that is there any way when we click on the Name header, it should sort the name list. As we see in some programs.
I hope there is a way to do it. But I dont know how . Please help me.
Darkshade
List View Sort In Date Order
Hi everyone, I'm stumped... maybe someone has an answer in this forum.
I have a listview that has 3 columns, one of them is just a simple description, the other is a numeric name, and the third is a date. I need to be able to sort in descending order when clicking on the header of each column. The description field is no problem, I just use listview.sort. The problem is when I try to sort dates, if I use the same thing I get 8/01/01 before 12/01/01 because 8 comes after 1 alphabetically... is there anyway to do this? I can only think of clearing the listview, sort the dates and then load them to the listview again, but that would take too long... and it seems like going the long way about it.
Please help!
Monica
Can I Sort A List View By A Numeric Field
I have a list view which I populate at run time, including creating the column headers. I don't know exactly what the columns are going to be at design time.
I want the column to be sortable when a user clicks on the column header but a list view uses a text sort by default, so in a numeric column 99 will appear to be higher then 100. Normally I'd get around this by hiding a column with the numeric values left padded with zeros and then sort by that instead but, due to the dynamic nature of the columns, that's going to be a bit of a nightmare to manage.
Does anyone know of a way I can 'tell' the column it's a numeric so that it sorts in a numeric fashion, or maybe override the sort algorithm myself?
Cheers
Dec
Sort An Array Like &"Sort By Name&" In Windows Explorer
I want to sort an array I created the same way it would be sorted if the contents of the array were files in a folder and I right-clicked and hit Sort by Name.
The contents of my array (Files()) are filenames starting with a number and then they may or may not have a trailing letter.
Example Files():
Files(0) = 1
Files(1) = 2
Files(2) = 2a
Files(3) = 3
Files(4) = 4
Files(5) = 5
Files(6) = 6
Files(7) = 7
Files(8) = 8
Files(9) = 9
Files(10) = 10
Files(11) = 10a
Files(12) = 10b
Files(13) = 11
Currently, when I output the array it would show it like this:
1, 10, 10a, 10b, 11, 2, 2a, 3, 4, 5, 6, 7, 8, 9
I want it to show like this:
1, 2, 2a, 3, 4, 5, 6, 7, 8, 9, 10, 10a, 10b, 11
So basically I want it to sort by the numerical value and then by the trailing letter. The "Sort by Name" windows explorer sort feature would sort those exactly how I want them, but VB doesn't.
How would I go about doing that?
Mimic Windows Explorer File View
Is there an ActiveX control or other, that I can insert onto a form and it will display files/directories like in Explorer (right window)? I understand how to use the API commands to handle files, I just need a control to display them. The FileListBox does not work for me as it does not contain Icons nor the capabilities associated with Explorer.
Launching Windows Explorer With View: Details
This could be done not just in VB but even in the Windows "Run..." command line.
If I write "explorer" there, then the Windows explorer starts, but how can I select if the folders window shows or not, or the kind of view (Thumbnails, Tiles, Icons, List, Details) or anything else I could select?
List View Find Text By Corrosponding Columns
Hi, i have a list view with 2 coumns and it retrieve information from a server and it contains different amounts of information at once.
What i need to do is locate in the first column of the listview anything containing
the index "hostname" then go retrieve the hostname which would be in the next column in the exact row. So it looks like this
Column 1 - Column 2
=====================
ip add - 192.168.blahblah
hostname - TheTestName
i want to retrieve "TheTestName" by finding the column "hostname" but i have no ideas how to achieve this. If anyone could help me out that would be great.
2 Qs : Timer And How Do I Hide/unhide Columns In A List View?
hi,
2 questions
For a listview, I want the user to choose the columns for a specified output though all the columns will be filled with data , i want to display only those columns which the user selects(Like we have it in windows explorer). Currently I make the width of the hidden column as - 0 but that the user can just keep his mouse on the header and drag to see the hidden column. How do I actually hide it???
Second question:
I have just recently find out that one cannot set the interval time of a timer for than 65000 millisecs that is apporx a minute. How do I set the interval of a timer for more than a minute say 3 minutes?
Thanks.
Imitating Windows Explorer's Thumbnail View In A Form
Greetings!
I have a client who has put forth the requirement that I provide him a screen with a Windows Explorer-style thumbnail view of all images in a given directory. The idea is to let the user see thumbnails of images that relate to the record they are currently viewing on a form.
I've tried the FileListBox control, and can't seem to find a way to get it to do a thumbnail view. Is there a way to do it, or do I need to use another control?
Displaying Sort Direction Icon On List View Column [not Resolved]
Hi team
I want my app to display sort arrows on the sorted list view column.
I can get the sort icon to the left of the column header text, but I would like the icon to be on the right of the text like Windows explorer.
Does anyone know how to move the icon from the left to the right of the text?
Thanks
FW
How To Implement Windows Explorer Style File List
I currently am using an older style DriveListBox/DirListBox/FileListBox combination to allow my user to select multiple files in a given directory.
How do I implement a Windows Explorer style interface (left pane with a tree, right pane with a file listing) that will allow the user to select multiple files, and for me to get the list of selected files?
Thanks.
Windows Vista Shell/Explorer List Control
Hello,
I need to include a file browsing component in my program. What I need is similar to the ListView control in comctl32.ocx.
However, I need it to have the Windows Vista style, and the ability to set the icon size from 16 x 16 to 256 x 256 (like the Common Dialog controls in Vista). Additionally, Windows (Vista) Explorer, and the Common Dialog controls, have highlights when you mouse-over a icon.
Does anyone know how to do this? I have researched this, and it seems that this is done through shell32.dll, with the SHCreateShellFolderView declare.
I found this on the internet, which appeared to be what I want, but it doesn't have the Vista styles:
http://btmtz.mvps.org/enumdeskvb/
I would appreciate any assistance or advice.
Kind Regards,
Using A List In Excel To Move Files Between Directories In Windows Explorer.possible?
I have a large excel file where one of the fields is "File Name" (TRD011.pdf as an example)...I have all the .pdf files in a folder...these pdfs are associated with a property and I want to use the list in excel to only move some of the files to another directory...how can I accomplish this? The volume is large, so I'm looking for a way to semi-automate this...also, I would like to print the files as a separate operation. Is there code that will perform these operations? Thanks!
Using List View Control In Windows Common Controls 6
Using a list box, am trying to show data from a database which the data is in access. The forms layout is setup that when your asked to enter a surname i.e Smith, it should display all the names begining with s until you type sm then narrow it down etc..
Please Help
How To Change Windows Common Dialog Box's List View Style
Hi!
I want to change the default list mode to report mode for list view used in windows file open / save common dialog box.
Even through APIs I see no such parameter which would change the default display?
How do I change it before / on opening a file open / save common dialog box?
Need Bubble Sort To Read Two Seperate Text Files And Sort Data Into One List
I have two seperate text files, have to read the data from both, such as:
(file one)
2, Tom
5, Bill
3, Tony
7, Charlotte
1, Pedro
etc.
(file two)
6, Penelope
8, Joann
4, Mark
10, Jose
9, Gerald
etc.
Then open, read and sort the two files, then put that data into combined order (by the number) to come out as one list:
1, Pedro
2, Tom
3, Tony
4, Mark
5, Bill
6, Penelope
7, Charlotte
8, Joann
9, Gerald
10, Jose
etc.
My exposure so far with Bubble Sort has been comparing and sorting words that were entered into text boxes. That is the only code I have and does not match this current scenario. Need help with code on opening both files simultaneously and then bubble sorting. I know this needs to be an array.
Can someone tell me what to do or show a similar example I could follow? Thank you for any help.
How Can I Know User Visited A Site Using Windows Explorer( Not Internet Explorer)
I have made a program which keep track of site visited by users through internet explorer but I am unable to get it when user visited it through windows explorer. can I get any function which gives the information when user visited a site using windows explorer or whether it's possible to stop user to visit a site using windows explorer he will only visit a site using internet explorer only.
Please help me out .
Thanks
Sort By Different Columns
How do I get a listview in report view to sort in ascending or descending order by the column that is clicked. I tried:
Code:
Private Sub Listview_ColumnClick()
With Listview
If (.SortOrder = lvwAscending) Then
.SortOrder = lvwDescending
Elseif (.SortOrder = lvwDescending) Then
.SortOrder = lvwAscending
Endif
End With
End Sub
but that sorts by the first column no matter which column you click on. Do I have to rearrange the column indexes whenever a column is clicked or what?
WHAT ABOUT COLUMNS SORT?
thanks alfredo,
I tested your comments and sorted my croostab rows,but whats your idea about
sorting columns on their respective totals?
bye
Visual Basic List View Control To View Network Computers
Hi,
I am working on simple network connect utility and ready with the functinality. But I am stuck at a very important aspect of the GUI where I need a List View Control that will view the computers from the available LAN domains. And will let us select a particular computer on expanding the domain List Item. If not a list view then a treeview rather.
Also will this control let me select a NETWORK COMPUTER ONLY but not shared folders on its individual drives. Only computers has to be selected. Not the nodes (folders) shared at them.
Thanks.
Vinitsankhe.
List View PopUp Prob (lvwIcon View) *Resolved*
Hi all,
I have a listview in large icon view (lvwIcon). I have a popup menu displaying some options when the user right clicks an item that is specific for that item.
My question is this -
I want a different popup menu to show when the user right-clicks on a blank area of the listview which would display general options.
In my testing, whenever a blank area is clicked, the selected item is the first item (if none had been selected) or the current selected item (if one had already been selected).
I currently use the selecteditem.text to determine what pop up menu is to be used.
I guess in theory the code might be something like ;
Code:
If lvwMain.SelectedItem = Nothing then
PopupMenu mnuGeneral
Else
PopupMenu mnuSpecific
End If
Any help would be greatly appreciated.
Cheers
Jack
Sort By Columns And Rows
Hi,
I have an excel file with records from A1 to U20 (cells). This needs to be sorted in alphabetical order from A1 to A20 then B1 to B20...and so on till U20. That is starting from A1 column downwards and then from B1 downwards.....till U1 and downwards.
Can anybody give me a code for doing this, or is there a way out in excel itself.
Thanks,
John.
Add, Sort, Keep Track Of COlumns
Here is the problem:
In the first Row of my worksheet. Starting at COlumn B, I am programatically adding a varible number of columns. Once I have added all of my columns I would LIke to sort the first row. however. If I select the entire row the "blank" value in Column A screws up the whole operation.
here is my code
For x = NumberPositions To 2 Step -1
Sheets("XYZ").Range("B1").Value = "=Job_Class!B" & x
Sheets("XYZ").Range("B1").Select
Selection.EntireColumn.Insert
Next x
'Delete the Extra Column Created
Sheets("XYZ").Range("B1").Select
Selection.EntireColumn.Delete
Once this is done, I would lIke to sort the First Row.
Any suggestions.
THanks
Vba Sort Columns And Print
Hi
Below is sum vba coding which is used to print out a new file according to the first letter of a title column! so bascially i will get a-z.htm files and each file will have the same letter titles listed in them, so all the 'a' titles will go to the a.htm file, 'b' titles to b.htm etc (hope that made sense)!
i have 2 problems with this
1. I need sum vba coding that will sort the title column in alphabetical order before it prints to files!
2. when it prints each title to its file i want the whole list to print! but in this case it keeps overwriting the file so i get only the last one line printed in each file!
this is a little section of my coding:-
rs.Open strSQL, strConnect
Open "C:vbdbindex_A.htm" For Output As #1
strA = "A"
rs.MoveFirst
Do Until rs.EOF
strRecno = rs.Fields("Recno").Value
strTitle = rs.Fields("Title").Value
strId = "<a href='{$url}MyLibrary/PILS/azindex.php?page=" & strRecno & "'>" & strTitle & "</a>" & "<br>"
strB = UCase(Left(strTitle, 1))
MsgBox (strB)
If strA = strB Then
Print #1, strId
Else
Close #1
Open "C:vbdbindex_" & strB & ".htm" For Output As #1
Print #1, strId
End If
rs.MoveNext
Loop
Close #1
can any1 help pls?
Sort Columns In Msflexgrid
Is it possible to sort multiple cloumns in msflexgrid.I have a grid where I want to sort column 6 & then column 3.Column 6 contains string value & column3 contains text like S 1030-031 3372 0000.doc.These are doc files from msword.I am able to sort coulmn 6 but am not able to do the same with column3.In column 3 i want to sort the records by taking the 031 value and the sort the records according to the number.Instead of 031 there may be some other numeric value & instead of 3372 there may be some other value.How do i go about it?
Explorer Columns
I need to know where Windows Explorer keeps it's settings for which columns are displayed. To see what I mean, open up Windows Explorer, click the View menu, and select "Choose Columns." You can choose which columns are displayed, their order, and their width. I can't find the settings in the registry...but then again I don't know what in the registry to look for. If you know where these settings are saved PLEASE let me know.
Thanks!
|