Results 1 to 6 of 6

Thread: Loading a file...

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Nov 2002
    Posts
    216

    Loading a file...

    How do i load a document onto a rtf? in the vbcodebook it asks the user to open it, i just want to open one that comes with the app... if you have any questions ask...

    Thanks

  2. #2
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    What are you using to make the document? Word or Wordpad can save to RTF.

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Nov 2002
    Posts
    216
    I have Wordpad and i would use that to to save it as an RTF but how do i (line of code) load it up when the user presses the treeview

  4. #4
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    You have to use the Richtextbox. I think the .NET rtb still has methods to load/save rtf files if not then assign the rtf text to the rtf property of the Richtextbox.

  5. #5
    Hyperactive Member RealNickyDude's Avatar
    Join Date
    Nov 2002
    Location
    Watching you through the hidden camera :o
    Posts
    435
    I don't know wheter you've sorted this out, but try this:

    VB Code:
    1. RichTextBox1.LoadFile("<path and file>", RichTextBoxStreamType.RichText)
    I'll add this to the VBCodeBook
    [vbcode]
    On Error GoTo Hell
    [/vbcode]:¬) Nicky : Why not try VBCodebook.NET.

  6. #6

    Thread Starter
    Addicted Member
    Join Date
    Nov 2002
    Posts
    216
    ok thanks nicky

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width