An alternative form of ASPdbNET to include system options.
Namespace:
TornadoAssembly: Tornado (in Tornado.dll) Version: 12.6.0.9 (1.0.0.0)
Syntax
| C# |
|---|
public string ASPdbNET( string MainParams ) |
| Visual Basic (Declaration) |
|---|
Public Function ASPdbNET ( _ MainParams As String _ ) As String |
Parameters
- MainParams
- Type: System..::.String
"New=True | NoTitle=True| Q=Quick Table| D=Quick DSN| Ajax=True"
Return Value
Returns entire content od ASPDBNET. The other way is to use GET_ASPDBNET.
Examples
Ajax = true will activate AJAX to display the output of ASPdbNet w/o screen refresh. This example illustrates the SQL changes upon re-entrance when a 'New=True' condition is set.
Dim x As New Tornado.z x.ASPdbNET("D=NWIND|Q=Orders|Ajax=t")
<script language="VB" runat="server"> Sub Page_Load(Src As Object, E As EventArgs) Dim Emp As String = "Nancy,Andrew,Janet,Margret,Steven,Micheal,Robert,Laura,Anne" Dim ID, Box6, Condition As String Dim GD As New AsposeDb.GetData() Dim LastUnit As String = GD.Get_Unit Dim M1 As New ASPdbNet.z() '... Create SBox With M1 .dbQP = "U=6| M=ty=SBox!SboxMacro=({{1,2,3,4,5,6,7,8,9}}~{{" & Emp & "}})" .dbTextHolder = "Title=Select an Employee" <Font color="blue">.ASPdbNet()</Font> End With '... if Sbox is clicked then save the screen for inactive display Condition = "" '... PostBack If LastUnit = "6" Or Session("Box6") = "" Then Session("Box6") = "%3cCenter%3e" & GD.Get_Sbox(6) & "%3c/center%3e" Session("ID") = GD.Get_SelectBoxSelection(6) '...Force New Entry - SQL changed - this is not the same as New=True in dbCommonTable Condition = "New=True" End If '... display active or inactive Sbox Response.Write(Session("Box6")) Dim EmpArr As String() = Split(Emp, ",") Dim M2 As New ASPdbNet.z() With M2 '... build SQL and drop list according to selected value .dbQP = "U=7| M=Grid| ps=5| D=NWIND| ni=b5,add| gdf=0,1,2,3,7|Bm=orders;0|" & _ "Q=Select * FROM Orders where EmployeeID = " & Session("ID") .dbEditAddFlds = "fi=EmployeeID|Ty=ROADD|Def=" & Session("ID") & "," & _ "fi=CustomerID|ty=SelectBox|val=cusID" .dbCommonTables = "i=cusID|sql=SELECT CustomerID FROM Orders " & _ "where EmployeeID = " & Session("ID") & "; " & _ "ind=empID,empName| sql=SELECT employeeid, lastname FROM Employees" .dbLookUpFlds = "fi=employeeid|key=empID|Look=empName" <Font color="blue">.ASPdbNet(Condition)</Font> End With End Sub </script>
<script language="VB" runat="server"> Sub Page_Load(Src As Object, E As EventArgs) Dim z As New Tornado.z Dim GD As New Tornado.GetData z.dbQP = "U=88| D=NWIND| Q=Orders| GDF=0,1,2,3| S=2| iv=t| Th=ti=Web Control Demo!sub=Hello" <Font color="blue">z.ASPdbNET("notitle=true")</Font> Table1.Rows(0).Cells(0).Text = GD.Get_Title(88) Table1.Rows(1).Cells(0).Text = GD.Get_ASPDBNET(88) End Sub </script>
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="WebForm4.aspx.vb" Inherits="xapsx.WebForm4"%> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> <title>WebForm4</title> <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR"> <meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE"> <meta content="JavaScript" name="vs_defaultClientScript"> <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema"> </HEAD> <body MS_POSITIONING="GridLayout"> <form id="Form1" method="post" runat="server"> <asp:Table id="Table1" style="Z-INDEX: 101; LEFT: 112px; POSITION: absolute; TOP: 56px" runat="server" width="561px" height="424px"> <asp:TableRow VerticalAlign="Middle"> <asp:TableCell></asp:TableCell> </asp:TableRow> <asp:TableRow> <asp:TableCell></asp:TableCell> </asp:TableRow> </asp:Table> </form> </body> </HTML>
<script language="VB" runat="server"> Sub Page_Load(Src As Object, E As EventArgs) Dim x As New Tornado.z x.ASPdbNET("Q=employees|D=Nwind") End Sub </script>