Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Got a toe stuck in the waters....
Message
General information
Forum:
Visual FoxPro
Category:
Visual FoxPro Beta
Title:
Got a toe stuck in the waters....
Miscellaneous
Thread ID:
00931679
Message ID:
00931679
Views:
80
First attempts at OOP.

I've been writing or attempting to write what I consider prime requisites for "converting"
my DOS application to Windows.

I'm deeply torn between staying with Foxpro (VFP9) as the primary platform, or Delphi as the
development tool and Foxpro as the DBMS.

My biggest fear is getting six months into the project just to find out "I can't do that.".

I'm a huge fan of Foxpro and it's community, but having said that. The marketplace is littered with Foxpro Solutions that just couldn't make it.

Many because the developers where less skilled, but many because VFP just couldn't create a commercially acceptable product in many markets. VFP products are very identifiable just from the GUI features, or lack there of.

One clear example that comes to mind is software for Dentists. There was a large number of very good Foxpro Applications, but when the next generation like Dentrix (written in Delphi) came along, they all died. This scenario has been repeated in many niche markets (VFP's forte).

Like these products, mine is primarily a Desktop Application, Foxpro's true strength.

I have little interest in .NET or WEB Enabled applications (as of now). When I do, there are numerous options superior to VFP for the purpose, which still access the VFP DBMS.

I'm a "Developer" not a "Programmer", so my take on VFP is slightly different than those looking for a career as a VFP Programmer.

It would seem that the days of working with one tool are long gone and it is necessary to be fluent in at least a couple of development languages.

The learning curve in VFP will be much shorter than Delphi or C++, I have no interest in VB. But, the Development Environment and tools available to Delphi are very impressive.

After putting together a concept(RAD)from the DOS program all the pieces are there and look great. The programming is a different story. Every line is a new learning challenge.

When I go back to VFP it's the opposite. The coding is not problem, but I feel severely limited in trying to create a visual interface that to some extent works like the DOS application (I.E.; the trademark features). I have the Codemine Framework which provides many of the tools that come with
Delphi, but even then it's like I would have to create a large number of new components that are readily available in other environments.

Here are the specific questions:

Many of the tools are available as ActiveX components. These all seem to have some limitations in placement on forms and re sizing... (Calendars for instance). Is that true or is it just me..?

A favorite tool in Delphi is the "Panel", which allows for easy placement of objects on a form and automatic re sizing, as well as a few "Style" tricks. Can some or all of this be emulated in VFP..?

I will need to access a major Internet Site and integrate into the APP.. They provide assistance in integration with sample code for VB and Delphi. I have attached the VB Sample.

What tools are necessary and what are the basic steps for accomplishing this task in VFP...?

The Invoice System (DOS) is a major requirement. Currently it is all procedural code using modules for Header,Body,Breaks,footers, etc... Code loops through the main table Items (objects)each have different print styles. Text enclosed in boxes with title in the box frame. Many print options, like trailing dots from item to price. Formatted Tables.

Items are in "outline" form with a descriptive caption line (created automatically) with lines and boxes to include subject titles.

Since I have never used the built in Report Writer, can this sort of process be created in VFP9..?

If I had to leave VFP, there are only two thing that are irreplaceable. Hentzenwerks Books and the VFP Community.

Here is the sample VB code:
'*******************************************************************************
' WorldPac Client Automation Protocol
' WorldPac DIAL / WCAP.DLL Demonstration
' For information about wcap see www.worldpac.com/wcap
' For more information about wcap.dll see www.worldpac.com/wcap/wcapdll.html
'
' Visual Basic Edition
'*******************************************************************************

Option Explicit
'*******************************************************************************
'Start server
'*******************************************************************************
Private Sub btnStartServer_Click()
  WCAPStartServer
  
End Sub

'*******************************************************************************
'Register callback procedure with DLL
'*******************************************************************************
Private Sub btnRegisterReceive_Click()
  WCAPRegisterReceive AddressOf Module1.CalledBack
  
End Sub

'*******************************************************************************
'Connect to DIAL
'*******************************************************************************
Private Sub btnConnect_Click()
Dim bRes As Boolean

  If Not WCAPConnected Then
    bRes = False
    If WCAPConnect("localhost", 17943) Then
      bRes = True
    End If
  End If
  
End Sub

'*******************************************************************************
'Send properties of this application to DIAL
'*******************************************************************************
Private Sub btnSetProps_Click()
Dim sWork As String
  If WCAPConnected Then
    sWork = "<?xml version=""1.0"" encoding=""UTF-8""?>"
    sWork = sWork & "<?xp Request=""805349""?>"
    sWork = sWork & "<!DOCTYPE SetClientProperties SYSTEM ""http://www.worldpac.com/wcap/SetClientProperties.dtd"">"
    sWork = sWork & "<SetClientProperties>"
    sWork = sWork & "<Caption>XML'er</Caption>"
    sWork = sWork & "<Win32WindowHandle>" & Form1.hWnd & "</Win32WindowHandle>"
    sWork = sWork & "</SetClientProperties>"
    sWork = sWork & "<?xp /?>"
    
    WCAPSend sWork
  End If
  
End Sub

'*******************************************************************************
'Show Price and availability in DIAL
'*******************************************************************************
Private Sub btnShowPnA_Click()
Dim sWork As String

  If WCAPConnected Then
    sWork = "<?xml version=""1.0"" encoding=""UTF-8""?>"
    sWork = sWork & "<?xp Request=""1234""?>"
    sWork = sWork & "<!DOCTYPE ShowPnA SYSTEM ""http://www.worldpac.com/wcap/ShowPnA.dtd"">"
    sWork = sWork & "<ShowPnA>"
    sWork = sWork & "<ProductID>140 830 05 70</ProductID>"
    sWork = sWork & "</ShowPnA>"
    sWork = sWork & "<?xp /?>"
  
    WCAPSend sWork
  End If

End Sub

'*******************************************************************************
'Send request to get makes table
'*******************************************************************************
Private Sub btnGetMakes_Click()
Dim sWork As String
  If WCAPConnected Then
    sWork = "<?xml version=""1.0"" encoding=""UTF-8""?>"
    sWork = sWork & "<?xp Request=""78GetMakes""?>"
    sWork = sWork & "<!DOCTYPE GetMakes SYSTEM ""http://www.worldpac.com/wcap/GetMakes.dtd"">"
    sWork = sWork & "<GetMakes/>"
    sWork = sWork & "<?xp /?>"
  
    WCAPSend sWork
  End If
  
End Sub

'*******************************************************************************
'Disconnect socket connection from DIAL
'*******************************************************************************
Private Sub btnDisconnect_Click()
  WCAPDisconnect
  
End Sub

'*******************************************************************************
'Close application
'*******************************************************************************
Private Sub btnClose_Click()
  End
  
End Sub


'*******************************************************************************
'Form is unloading, disconnect DLL socket connection from DIAL
'*******************************************************************************
Private Sub Form_Unload(Cancel As Integer)
  WCAPDisconnect
  
End Sub
Next
Reply
Map
View

Click here to load this message in the networking platform