Search:

Type: Posts; User: MarkGB

Search: Search took 0.03 seconds.

  1. VS 2012 Re: Object not set to an instance error on first select of treenode only

    It gives the directory C:\working.

    As kaliman79912 suggested with his location of a Breakpoint its the tvprogress.selectednode.fullpath thats empty. Once the error is suppressed and the node...
  2. VS 2012 Re: Object not set to an instance error on first select of treenode only

    I'm just learning with this. I've removed both suggestions from ident. I am aware that the code could be written far better but this is a first attempt so I'm just finding my feet and this works for...
  3. VS 2012 Re: Object not set to an instance error on first select of treenode only

    Thanks, tried that and its the tvProgress.SelectedNode.FullPath which is empty. Don't quite understand as the path exists?
  4. VS 2012 Object not set to an instance error on first select of treenode only

    I've been struggling with this for a while and finally gave in and am seeking some help.

    The below runs on a `After Select` event in a treeview. The code runs absolutely fine but since I've made a...
  5. VS 2012 Changing & Indicating Default Printer Tool Strip Menu Item Control

    I'm using the below to generate the list of installed printers and add them to a Tool Menu Strip


    Private Sub PrinterToolStripMenuItem_DropDownOpening(sender As Object, e As EventArgs) Handles...
  6. VS 2012 The process cannot access the file error on Vista but not Win 8.1

    I'm having a bit of trouble with a File System Watcher and what looks like Windows Vista. My project has been built on Windows 8.1 as an Administrator and shows no signs of these error messages I get...
  7. Replies
    5
    Views
    7,137

    VS 2012 Re: Remove item from listbox populated from query

    Thanks, the removing from the original database is the bit i'm more concerned with not doing!

    I'll see what i can come up with
  8. Replies
    5
    Views
    7,137

    VS 2012 Re: Remove item from listbox populated from query

    If i remove the item from the datatable will it still be available if selecting a different node?
  9. Replies
    5
    Views
    7,137

    VS 2012 Remove item from listbox populated from query

    The below code is populating a listbox form a data query when a node with a specific string value is clicked on in a treeview. The items that are displayed in the listbox can then be double clicked...
  10. VS 2012 Re: Change treenode image depending on node text

    The nodes are created at runtime and on a refresh by getting a list of directories and files within the target folder and adding them to the treeview.

    I was thinking of adding a routine that maybe...
  11. VS 2012 Change treenode image depending on node text

    I have a treeview which is used as list for daily jobs, files are added to the root node and these then appear as child nodes. Once the job is complete the files behind the node are zipped up,...
  12. Replies
    0
    Views
    691

    VS 2012 XLSM files showing as duplicate tree nodes

    The below code searches through a directory and returns the relevant defined files as treenodes in my treeview.

    The problem I'm having that if the file has an extension .xlsm (and possibly .xlsx...
  13. Replies
    4
    Views
    1,109

    VS 2012 Re: File Extension for Treeview Node

    If I use the Process.Start and double click on the node that has the extension .mdb then it will open Access. The .mdb files are used in some other bespoke software that requires some other...
  14. Replies
    4
    Views
    1,109

    VS 2012 Re: File Extension for Treeview Node

    I'm really asking on how to find the file extension that relates to the treenode
  15. Replies
    4
    Views
    1,109

    VS 2012 File Extension for Treeview Node

    Hi,

    In my treeview i have a collection of nodes that are file types (.xls, .pff, mdb for example) that have their extension shown in the node. I'm using Process.Start to initiate the programs from...
  16. Replies
    4
    Views
    685

    VS 2012 Re: SQL duplicating results

    Thanks both of you - tried both answers and they both worked. Thanks again
  17. Replies
    4
    Views
    685

    VS 2012 [RESOLVED] SQL duplicating results

    Running the below SQL query from a VB.Net project into a Access Database. This all works fine however i need to add some pre-defined rows if the query returns nothing.

    I've added the following...
  18. Replies
    8
    Views
    1,490

    VS 2012 Re: List all parent nodes in an array

    OK so whats the best way of accomplishing that please?
  19. Replies
    8
    Views
    1,490

    VS 2012 Re: List all parent nodes in an array

    Yes, I suppose so if you put it like that!
  20. Replies
    8
    Views
    1,490

    VS 2012 Re: List all parent nodes in an array

    Date Node
    | |___Parent Node
    | | |___Child Node
    | | |___Child Node
    | |
    | |___Parent Node2
    | |__Child Node2
    |
    Date Node2
    | |___Parent Node3
  21. Replies
    8
    Views
    1,490

    VS 2012 List all parent nodes in an array

    Hi,

    I have a control that has GrandParent, Parent & multiple Child nodes and would like to return all the parent nodes into an array (or Listof) so i can reference them from a listbox. I only...
  22. VS 2012 Re: Add treenodes from files within directories

    Thanks both so much, you've helped massively
  23. VS 2012 Re: Add treenodes from files within directories

    Thanks, thats working with searching for a single file extension however if i try to search and add 2 extensions (.xls & .pdf) for example it returns 2 sets of parent nodes.

    This part of the code...
  24. VS 2012 [RESOLVED] Add treenodes from files within directories

    Hi, Im using the below code to look through a directory and add the folder names as treenodes to a treeview control. I'm needing then to search the folders and add to each respective node any file...
  25. Replies
    4
    Views
    3,515

    VS 2012 Re: Get Child Node Name

    Need to try it but that looks just what I'm looking for. Thanks so much
  26. Replies
    4
    Views
    3,515

    VS 2012 Re: Get Child Node Name

    Sorry 1 Parent Node with multiple child nodes that are folder names within 1 directory.

    I actually have a listbox that, when the child node is selected, a SQL query is executed and some file names...
  27. Replies
    4
    Views
    3,515

    VS 2012 Get Child Node Name

    Hi,

    Is there any code that can display the name of a child node in say a Message box on an AfterSelect or click event?

    The nodes that i have are basically folder name's and i just need to be...
  28. VS 2012 Re: Object Error when trying to run a query that involves a Date Time Picker

    Thanks jmcilhinney, let me give that a try
  29. VS 2012 Re: Object Error when trying to run a query that involves a Date Time Picker

    Thanks, I understand that the error message is displaying as it thinks the selected item is returning Nothing however towards the end of the 1st code there is this block


    If...
  30. VS 2012 Re: Object Error when trying to run a query that involves a Date Time Picker

    the line that throws the exception is


    If AllDetails(n).uName & " - " & AllDetails(n).uCode & " - " & AllDetails(n).uOps = lstProgress.SelectedItem Then

    and it gives the...
  31. VS 2012 Object Error when trying to run a query that involves a Date Time Picker

    Hi,

    I have the following code that runs on Load and that reads from text files in a directory and stores the info in an Array. This then loads the relevant info into a listbox based on the date...
  32. Replies
    12
    Views
    1,013

    VS 2012 Re: Defining multiple extensions to string value

    Hi, I've tried by both ident & dday9's answers and neither work for me.

    The code I posted does exactly what i need for now however i need to change this


    If MyVariable = "Spreadsheets" Then...
  33. Replies
    12
    Views
    1,013

    VS 2012 Re: Defining multiple extensions to string value

    Yes sorry - the original code i've posted was taken from a VB6 application which i'm updating in VS12. The code i have used worked in VS12

    Thanks for all your help
  34. Replies
    12
    Views
    1,013

    VS 2012 Re: Defining multiple extensions to string value

    Sorry the code i'm using is below


    Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged
    Dim lyxfle As New...
  35. Replies
    12
    Views
    1,013

    VS 2012 Defining multiple extensions to string value

    Hi,

    Below is a snippet of my code which helps determine which files to pull through to a listbox via a dropdown result. What I'm struggling to do is make it so it also recognises .xlsm & .xlsx...
  36. Replies
    11
    Views
    5,293

    VS 2012 Re: Open file from Listbox

    Thanks for all your help, I'll give them all a try
  37. Replies
    11
    Views
    5,293

    VS 2012 Re: Open file from Listbox

    Sorry Ian,



    This is exactly what i want to do but I only want it to show the the file name in the listbox

    Currently the file path would be C:\Dropbox\Test

    Hope that makes more sense.
  38. Replies
    11
    Views
    5,293

    VS 2012 Re: Open file from Listbox

    Ah thanks let me have a play
  39. Replies
    11
    Views
    5,293

    VS 2012 Re: Open file from Listbox

    Thanks. however if I apply this to the List box click it opens a dialogue looking for a Picture File. I'm looking for that if i click on a file with the .pdf extension it will open the actual PDF...
  40. Replies
    11
    Views
    5,293

    VS 2012 [RESOLVED] Open file from Listbox

    Hi,

    Please excuse me I am very new to Visual Basic

    I have a listbox on a form that populates from a text file on a button click. This works fine but only brings through the fie name and not the...
Results 1 to 40 of 40



Click Here to Expand Forum to Full Width