Jump to content
Xtreme .Net Talk

badgerboy

Members
  • Posts

    12
  • Joined

  • Last visited

About badgerboy

  • Birthday 08/19/1986

Personal Information

  • Occupation
    Saturday Boy
  • Visual Studio .NET Version
    visual basic.net standard
  • .NET Preferred Language
    vb.net

badgerboy's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. thanks everyone but i found some code that worked.
  2. heres the errors this is the error i get on debug and runtime
  3. Hello, I have found the following code for an Save and Open file dialogs but Both JUST CRASH the program when executed heres the code Public fmainform As Form1 Public Sub open() Dim FileName As String Dim odlgtextfile As Object Dim txthtml As Object Dim statusbarpanel4 As Object Dim ts As StreamReader 'Dim form1 As New Form1() Try With fmainform.odlgtextfile .DefaultExt = "html" .DereferenceLinks = True .Filter = _ "Web files (*.html)|*.html|" & _ "All files|*.*" .Multiselect = False .RestoreDirectory = True .ShowHelp = True .ShowReadOnly = False .Title = "Select a file to open" If .ShowDialog() = DialogResult.OK Then FileName = .FileName ts = New StreamReader(.OpenFile) fmainform.txthtml.Text = ts.ReadToEnd() fmainform.StatusBarPanel4.Text = System.IO.Path.GetDirectoryName(fmainform.odlgtextfile.FileName) + "\" + System.IO.Path.GetFileName(fmainform.odlgtextfile.FileName) fmainform.Text = "HTML 2K3" + " " + System.IO.Path.GetDirectoryName(fmainform.odlgtextfile.FileName) + "\" + System.IO.Path.GetFileName(fmainform.odlgtextfile.FileName) End If End With Catch exp As Exception MessageBox.Show(exp.Message, fmainform.Text) Finally If Not (ts Is Nothing) Then ts.Close() End If End Try End Sub 'This is for the save dialog Public Sub save() Dim sw As StreamWriter Dim filename As String Dim statusbarpanel4 As Object Try With fmainform.sfd1 .AddExtension = True ' The default is True. .CheckPathExists = True ' The default is False. .CreatePrompt = False ' The default is True. .OverwritePrompt = True ' The default is True. .ValidateNames = True ' The default is False. .ShowHelp = True ' If the user doesn't supply an extension, ' and if the AddExtension property is ' True, use this extension. ' The default is "". '.DefaultExt = "txt" ' Prompt with the current file name ' if you've specified it. ' The default is "". .FileName = filename ' The default is "". .Filter = _ "Html files (*.html)|*.html|" & _ "All files|*.*" .FilterIndex = 1 If .ShowDialog() = DialogResult.OK Then filename = .FileName sw = New StreamWriter(filename) sw.Write(fmainform.txthtml.Text) End If End With Catch exp As Exception MessageBox.Show(exp.Message, fmainform.Text) Finally If Not (sw Is Nothing) Then sw.Close() End If End Try fmainform.StatusBarPanel3.Text = "Current work is saved" End Sub Please help thanking in advanced BadgerBoy
  4. i couldn't get it to work kept coming up with this error Overload resoultion failed beacause 'AddEllispe' accepts this number of arguements please help thanking in advanced Badgerboy
  5. is it possible to create shaped forms that look good. Can I set areas of the form to be transparent so it creates the illusion of it being shaped or not there but its just transparent. Also how can I preview HTML in a form or RTB (Rich text box) Thanking in advanced Badgerboy
  6. i dont know if this will help but try this http://www.codeproject.com/combobox/readonlycombo.asp
  7. thanks for that it worked
  8. I am trying to get the dat from one text box on a form to a rich text box on another form but how could i do this here is my program so far ps: dont ask about the name project catfish.zip
  9. thanks i mean add the current data to the file Basically a file>save function Thanks for the help as well
  10. Have you tried installing the new version of the .net framework? might solve ya problem
  11. I am trying to make a simple MDI HTML editor and am having difficultly defining the File>Close menu to close a highlighted MDIchild. Also I cant get the File>Save to update the .html file instead of re writing it
×
×
  • Create New...