Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Connection String
Message
De
22/06/2006 19:07:09
Randy Hooper
Ranco Business Software
Tampa, Floride, États-Unis
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01130047
Message ID:
01131000
Vues:
16
David Thanks. You put me on the correct track it works great. Is there not a command I can use for my code to continue to run. When it connects I have a wait window displaying .t.

Randy



>Randy,
>
>If you attach all your remoteviews to a single connection in the DBC, then you can just swap out the connectstring with a chunk of code:
>
>
>if ( "office machine name" $ lower( sys(0) ) )
>   lcOld = "homename"
>   lcNew = "officename"
>else
>   lcOld = "officename"
>   lcNew = "homename"
>endf
>
>? dbsetprop( "sqlConnection", "connection", "connectstring",
>   strtran( dbgetprop( "sqlConnection", "connection","connectstring" ), lcOld, lcNew ) )
>
>
>>David, thanks for the reply.
>>this has me very confused, I have made a connection called pcrconnect and have built my remote views as the data source pcrconnect I'm using a IP address that will allow me to hit the server in our office from my home office. So what I did I change the IP address in the pcrconnect connection to the name of the server in our office and recompiled the code and installed the exe on a work station in our office. I would have thought at this point this would work.
>>
>>But what is happening I get a connection failure and then the SQL server dialog box comes up with the IP address I used from my home office and not the name of the server. I can drill down and pick the server I want and all works well.
Foxpro is a sweet puppy

'cept it barks every now and then =)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform