6/9/2023 0 Comments Vb6 file functions![]() If PrintFileOut(Text1.Text, "D:\Binary.txt") = False Then MsgBox Err. Or, you could use 2 procedures, one to read it in and another to save the contents. Use Input to read it in or Binary Read Write for your purposes. This open the file for appending to it, not for reading it in. Thanks to Tim Hastings for the Base64 functions. Text1.Text = ReadTextFileContents("C:\VISUAL BASIC FILES\VB98\VB6 projects\FILEOPENTEST\FileTest.rtf")ĭwight RE: Appending text files from VB6 vb5prgrmr (Programmer) 7 Oct 03 01:42 VB6/VBA functions to convert binary string to Base64 string Here are some functions to convert a binary string, to a byte array, to a Base64 string and then back to a byte array and binary string. ![]() If Err Then Err.Raise Err.Number,, Err.Description ReadTextFileContents = Append(LOF(fnum), fnum) Public Declare Function XLLFunc Lib 'xlMath.xll' (ByVal emb As Integer, ByVal Data As Single, ByVal iFirst As Integer, ByVal iLast As Integer, Optional flgdt As Boolean, Optional flgstd As Boolean) If it were a DLL, it would be something like the above. Public Function ReadTextFileContents(filename As String) As String XLL function in VB6 to create a Stand-alone VB app. It raises no error, so I guess the syntax is correct, but when I run the program the text box remains blank. ![]() I have tried everything I can think of but can't seem to get the contents of a file loaded into the text box for appending. Actually I want the user to be able to add lines of text to an existing file from data he needs which he accesses from from my server. My latest project requires accessing text files from the user's hard drive for appending.
0 Comments
Leave a Reply. |