Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Connecting to VFP Data in ASP.NET
Message
De
06/01/2006 09:32:49
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Visual FoxPro et .NET
Divers
Thread ID:
01072118
Message ID:
01084037
Vues:
23
Yes it is expecting a parameter for country.
 <asp:SqlDataSource ID="vfpTestData" runat="server" 
   ConnectionString="<%$ ConnectionStrings:vfpTestDataConnection %>"
   ProviderName="<%$ ConnectionStrings:vfpTestDataConnection.ProviderName %>"
   SelectCommand="SELECT company, contact, country FROM customer WHERE (country = ?)">
   <SelectParameters>
      <asp:ControlParameter 
         ControlID="TextBox1" DefaultValue="" Name="country" PropertyName="Text" Type="String" />
   </SelectParameters>
 </asp:SqlDataSource>
Here: SqlDataSource sets datasource properties along with SelectCommand.
Following that "SelectPameters" tag adds a ControlParameter with ID "TextBox1" and other properties. TextBox1 is a textBox on ASP form and at run time ? is replaced with its text. Maybe you don't have TextBox1 on asp form?

UT is working well for me.
Cetin


>I hope you'll end up liking it, makes datasources/connections easier. As for the error, it didn't like WHERE (country = ?)
>Is it looking for something in place of "?"
>PS, is the UT experiencing errors, when I click "get the replies to my messages", I get a COM error.
>
>-T
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform