[Search for users]
[Overall Top Noters]
[List of all Conferences]
[Download this site]
| Title: | TeamLinks for Windows | 
| Notice: | Kit and ECO locations: See replies to note 8. o note 8. | 
| Moderator: | ORION::chayna.zko.dec.com::tamara::eppes  AN | 
|  | 
| Created: | Mon Aug 28 1995 | 
| Last Modified: | Fri Jun 06 1997 | 
| Last Successful Update: | Fri Jun 06 1997 | 
| Number of topics: | 2238 | 
| Total number of notes: | 9650 | 
1970.0. "Program that uses Teamlinks Viewers" by VAXRIO::63230::abreu () Fri Jan 31 1997 11:34
Hi,
   I have a customer that wants to use the viewers that come with Teamlinks.
They made a program in VB 3.0 following the example available in SDK.
  They create a text doxument with Notepad and then they call the program to
view this text document. The problem is that the document is not viewed
properly because some words are shown together with no space between them.
  I realized that this happens when I type  <CR> in notepad to go to
the next line.  It seems that the viewer uses a line larger than the one I
typed in notepad so that when the document is "viewed" , the words that were
at the end of one line and the begginig of the next one , are shown together.
   Any ideas .. what can be done ?
   I tested with Teamlinks 2.5 and 2.7 .
   I have the executable file availabe and the code I'll show below.
   Thanks ,
      M�rcia
Global Const CNV_Success = 1 ' Successful call to Conversion subsystem
Option Explicit
Dim sts As Integer
' Conversion subsystem function declarations
Declare Function ChkConverters Lib "CONVERT.DLL" (handle%, INfile As Any,
INformat As Any, inDataType As Any, DocTitle As Any, outfilespec As Any,
OUTformat As Any, OptionsFile As Any, flag%) As Integer
Declare Function DoConvert Lib "CONVERT.DLL" (ConvertDataHandle%) As
Integer
Declare Function DoView Lib "CONVERT.DLL" (ByVal handle As Integer,
ConvertDataHandle%) As Integer
Declare Function DoViewDelete Lib "CONVERT.DLL" (ByVal handle As Integer,
ConvertDataHandle%) As Integer
Declare Function FreeConverters Lib "CONVERT.DLL" (ConvertDataHandle%) As
Integer
Declare Function TLGetFileFormatTag Lib "CONVERT.DLL" (ByVal DOSFileName
As String, ByVal FileFormatTag As String, ByVal LenFileFormatTag%) As
Integer
Function ConvertOrViewDocument (INfile As String, INformat As String,
OUTfile As String, OUTformat As String, ConvOrView As Integer,
TheFormHandle As Integer, DocTitle As String) As Integer
' A function to convert or view a document
'   ConvOrView Flag values
'   1 = Convert
'   2 = View
'   3 = Draft Mode Viewer
    Dim Status As Integer
    Dim OptionsFile As String
    Dim OptionsFlag As Integer
    Dim ConvertDataHandle As Integer
    ConvertOrViewDocument = CNV_Success ' Assume success
    OptionsFile = " "
 
'    screen.MousePointer = 11
    Status = ChkConverters(ConvertDataHandle, ByVal INfile, ByVal
INformat, ByVal INformat, ByVal DocTitle, ByVal OUTfile, ByVal OUTformat,
ByVal OptionsFile, ByVal ConvOrView)
'    screen.MousePointer = 1
    If Status = CNV_Success Then
        '
        ' A converter is available; we can convert or view
        '
        Select Case ConvOrView
        Case 1  ' Convert
            Status = DoConvert(ByVal ConvertDataHandle)
        Case 2   ' View
            ' Use DoViewDelete so it cleans up afterwards
            Status = DoView(TheFormHandle, ByVal ConvertDataHandle)
            DoEvents
        End Select
    Else
        ConvertOrViewDocument = False ' Signal Failure
    End If
Convert_Over:
'   Free up resources even if we haven't managed to convert
    Status = FreeConverters(ByVal ConvertDataHandle)
End Function
Sub cmdvisualizador_Click ()
 
 Dim TheFormHandle As Integer
 Dim DOSFileSpec As String
 Dim sFormato As String
 Dim DisplayName As String
 TheFormHandle = Me.hWnd
 DOSFileSpec = "c:\lixo.txt"
 sFormato = "TEXT"
 sts = ConvertOrViewDocument(DOSFileSpec, (sFormato), DOSFileSpec,
(sFormato), 2, TheFormHandle, DisplayName)
End Sub
| T.R | Title | User | Personal Name
 | Date | Lines | 
|---|
| 1970.1 | A known bug in the text viewer. | TAMARA::HOVEY |  | Tue Feb 18 1997 07:24 | 12 | 
|  | The run together words is a bug in the mastersoft viewer which does wrapping.
It doesn't show up in teamlinks since it uses its own viewer for text 
in 2.5, 2.7.
Try pointing tlcvtvu.ini [AF] to w4w01_5a.
As for the size font choice, that's up to the application to decide. 10points
is rarely 10point on the screen... i.e. the application doesn't know if 
you have a 13" monitor or a 17"monitor, there is just some mapping between
the printer font and the screen font. 
Anyway, that's what the zoom/scale button is for.
 |