|
alistairhay -> Trying to assign result of query to a variable (10/23/2007 21:54:30)
|
I know this sounds very basic, but it doesn't work the way I am used to coding web pages. First time I am using expression web. I was to assign the result of a query to a variable so I can test the result, and if true, display something, if false, not display anything. Query is this : <asp:AccessDataSource runat="server" ID="VenueLookup" DataFile="App_Data/PublicHousePromotions.mdb" SelectCommand="SELECT * FROM [Venue] WHERE ([venueCode] = ?)"> <SelectParameters> <asp:querystringparameter Type="Int32" DefaultValue="1" Name="venueCode" QueryStringField="MyRef" /> </SelectParameters> </asp:AccessDataSource> What I am trying to do is this : <script> <% Dim JoinedDate as String JoinedDate = [venueDateSignedAgt] if JoinedDate <> "" then %> <span class="style32">Joined:</span><asp:Label Text='<%# Bind("[venueDateSignedAgt]","{0:d}") %>' runat="server" id="lblJoined" Font-Names="Comic Sans MS" /> <br/> <% end if %> </script> Any help would be hugely appreciated.
|
|
|
|