Radio Button And Datatype

Nov 26, 2007

Hi.
Am creating a database in SQLEXPRESS 2005 and have two fields male and female. In my form(vb 2005) i will assignin these to fields to a radio button. In designing the database which datatype should i use for the male and female field?
Thanks

View 4 Replies


ADVERTISEMENT

Radio Button

Dec 27, 2006

Hi,

I have one report,in my report i need to display parameters like this:

one radio button :Age and another radio button is Age Ranges

For the Age,I have to dispaly like two text boxes named 'From' and 'To'

For the Age Ranges,I have to display one drop down list contains values :20s,30s ..

In Reporting Services,Putting the Radio button is not possible,i think,If possible how to achive this.

Other workaround is i think Multivalued parameter which displays the Age and Age ranges

When we click on Age we need to display 2 textboxes

When we select Age Ranges we have to display Drop down list

If we select both :both 2 text boxes and drop down list.

Putting multi valued parameters for this requirement is not good and this is not the multi valued parameter concept.Please clarify me whether iam correct or not.

Thanks in advance



View 5 Replies View Related

DataBinding To Radio Button

Apr 27, 2006

I have a windows form containing some text boxes and radio buttons bount to an SQL Server database, with code like the following:

this.tbBorrowerLastName.DataBindings.Add (new Binding("Text", dsData.Tables["Results"],"BorrowerLastName"();

this.rbMale.DataBindings.Add(new Binding("Checked", dsData.Tables["Results"],"Male"))

If I add a new row and try to move there using the code below, nothing happens (neither movement to a new position nor error message), unless I remove the radio button bindings. (The same thing occurs if I attempt to move to any record that has a null value in the database field for a radio button).

myLastRow = dsData.Tables["Results"].NewRow();

dsData.Tables["Results"].Rows.Add(myLastRow);

I attempt to move by changing the value of the position property of the BindingContext object.

How can I retain the radio button bindings and still be able to add and move to a new row?

Any help would be appreciated.

View 1 Replies View Related

Radio Button Data Binding-how?

Jun 30, 2007

 hi,i have a DB that contains some tables.so i have a radio button group of tow radio button to display a field.now how can i bind this radio button group to this field for updating  and insert a new record?for more explain i brought a little of code below: in .aspx page i have: <asp:RadioButton ID="admin" runat="server" Checked="True" GroupName="membertype"
Text="admin" OnCheckedChanged="admin_CheckedChanged" /><br />
<asp:RadioButton ID="member" runat="server" GroupName="membertype" Text="member" /> -------------------------------------------------------------------------- <asp:ControlParameter ControlID="membertype" Name="isadmin"   Type="string" PropertyName="text" />-------------------------------------------------------------------------- UpdateCommand="UPDATE UserManagement SET UserName = @UserName, Password = @Password, FullName = @FullName, Description = @Description, UserID = @UserID ,isadmin=@isadmin,usercitycode=@location  WHERE (UserID = @Original_UserID)" note that the type of the "isadmin" field is "nvarchar(50)"thanks,M.H.H 

View 2 Replies View Related

Radio Button - Not Reqire To Select!!!

Oct 6, 2005

I am currently using a web form to insert data into SQL DB.  The radio button for Gender is not a require field. currently if I use this command is in VB'  cmd.Parameters.Add(New SQLParameter("@Gender", rblGender.SelectedItem.text)) >it work fine if the user select one of the radio button, if the user don't select any button then it will give an error.so I thought I can try the if else statement to see if it work, unfortunately it didn't either and error out on rblGender.SelectedItem.textex. If rblGender.SelectedItem.text <> "" then      cmd.Parameters.Add(New SQLParameter("@Gender", rblGender.SelectedItem.text))   Else      cmd.Parameters.Add(New SQLParameter("@Gender", ""))   End IFAny help would be appreciated.hydro

View 2 Replies View Related

Retriving Gender From Database In A Radio Button

Mar 10, 2006

i am storing gender in the database.i want to retrive it in one of the radiobuttons for male and female already present on the form . how can i?

View 1 Replies View Related

Populating Radio Buttons - Access Vs. MSSQL

Dec 10, 2007

Have recently migrated an Access database to MSSQL.

The following code worked in Access but fails in MSSQL


<input <%If (CStr(Recordset1.Fields.Item("Disclose").Value) = CStr("TRUE")) Then Response.Write("CHECKED") : Response.Write("")%> type="radio" name="Disclose" value="1">

<input <%If (CStr((Recordset1.Fields.Item("Disclose").Value)) = CStr("FALSE")) Then Response.Write("CHECKED") : Response.Write("")%> name="Disclose" type="radio" value="0" >


In Query Analyzer, when I run SELECT Disclose from TABLE, it returns the number 1.

On an ASP page, when I run Response.Write(Recordset1.Fields.Item("Disclose").Value) it returns TRUE.


Have tried changing the = CStr("TRUE") portion to = 1 but it fails to work either way.

Any ideas?

View 1 Replies View Related

How To Create Radio Buttons For Parameters In Reporting Services 2005

Nov 15, 2007



Hello,

I am creating a report that the user will pick a value from about 6 items. The project manager would like these values to be represented as radio buttons on the ReportViewer control. I am unable to determine how do create these 6 radio buttons.

Here is a simple example to demonstrate what I need. Lets say the report returns the total number of fruit in a stores inventory. The choices are: Apple, Banannas, Oranges, Grapes, Cherries, Water Mellon.

I have a variable @Fruit that I would like populated by the user and I want them to select which piece of fruit they want to see by selecting a radio button. Is there a way to do this using Reporting Services 2005 Report Designer?

Thanks,
Flea#

View 5 Replies View Related

T-SQL (SS2K8) :: Varchar Datatype Field Will Ignore Leading Zeros When Compared With Numeric Datatype?

Jan 28, 2015

Need to know if the varchar datatype field will ingore leading zeros when compared with numeric datatype ?

create table #temp
(
code varchar(4) null,
id int not null
)
insert into #temp

[Code] .....

View 4 Replies View Related

Numeric Datatype To Ssis Variable Datatype Conversion Problem

Apr 24, 2008



Good afternoon,

I have an issue with an ssis variable datatype.

The scenario is as follows:

I have a stored procedure:


PROCEDURE [dbo].[sp_newTransaction]



@sourceSystem varchar(50),

@txOut NUMERIC(18,0) OUTPUT

AS

insert into scn_transaction (sourceSystemName) values(@sourceSystem);

SELECT @txOut = @@identity


Whose purpose is to perform an insert into a table and return me the identity value of the inserted record, which I'll then use throughout the rest of my package. The identity column in the inserted table is numeric(18,0).

I execute the stored proc with the following sql with an OLE DB connection manager:

exec sp_newTransaction ?, ?

The first parameter is a string variable from earlier in the package, and the second is the output parameter. I have the following parameter mappings to the execute sql task:

User:ystxId output numeric 1 -1
User:ourceSys input varchar 0 -1

The proc is correctly called, and the row insesrted, however I get a type conversion error when SSIS attempts to map the return parameter to my package variable... I've tried all sorts of combonations, and can't seem to get it to execute.

At one point I wasn't returning a numeric, but rather an int from the stored proc, and all was well until I went to use the variable in a derived column later in the package, and the type was converted quite incorrectly (a 1 was 77799789080 or some such), indicating a type conversion error likely related to the encoding of the number.

I'd like to keep the datatypes as numeric and make ssis use those - any pointers are greatly appreciated as to what type my package variable should be to allow proper assignment of a sql server numeric type to it.

Thanks much,

B

View 6 Replies View Related

Transact SQL :: CTE To Peg Char Values To Int Values In Radio-style Chart

Aug 26, 2015

I developed the following T-SQL query that runs successfully, but I was looking for a more efficient and concise way to do this. Is there a CTE that can replace all of these case statements?  I've updated my query as below. Although this sample query works, it's not working for my real data.  Instead, I get an error.  At the bottom is the error part of my real query.I copied all of the tables from the first query block below.  But when I wrote the bottom query block, it underlined in red the words "answer" and "question."  It says "Invalid column name". 

if exists (select * from tempdb.dbo.sysobjects o where o.xtype in ('U') and o.id = object_id(N'tempdb..#hard_values')
) DROP TABLE #hard_values;
if exists (select * from tempdb.dbo.sysobjects o where o.xtype in ('U') and o.id = object_id(N'tempdb..#dummy_data')
) DROP TABLE #dummy_data;
if exists (select * from tempdb.dbo.sysobjects o where o.xtype in ('U') and o.id = object_id(N'tempdb..#temp')

[code]...

View 13 Replies View Related

Convert Char Datatype To Datetime Datatype

Sep 17, 2003

Database is SQL Server 2000

I have a field in a table that stores date of birth. The field's datatype is char(6) and looks like this: 091703 (mmddyy). I want to convert this value to a datetime datatype.

What is the syntax to convert char(6) to datetime?

Thank you in advance.

View 1 Replies View Related

Modify Nvarchar Datatype To Datatime Datatype

Mar 14, 2008

Hi,

I imported a table from Accees to SQL 7 with data in it.
I need to modify one of the datatype columns to "datetime" from nvarchar.

I tried to convert it manually, in SQL Server Enterprise Manager tool, but it gave me an error.

I also tried, creating another column "DATE2-datatype:datetime" and updating the column with the old one.

UPDATE users SET DATE2 = DATE.. But it also faild,..

How can I modify the column?

Thank you.

View 10 Replies View Related

Converting INT Datatype To BIGINT Datatype

Dec 15, 2005

HI,I have a table with IDENTITY column with the datatype as INTEGER. Nowthis table record count is almost reaching its limt. that is totalrecord count is almost near to 2^31-1. It will reach the limit with inanother one or two months.In order to avoid the arithmentic overflow error 8115, we would likechange the datatype from INT to BIGINT. we hope this will solve ourproblem.How do I approch this datatype conversion?. Since the data count ishuge, that leads to a long down time of database.we need better approach or solution for this problem?. kindly give mea better solution that will reduce the total downtime of the productiondatabase.?.Regards

View 1 Replies View Related

Text Datatype Vs Nvarchar Datatype

Feb 25, 2008



Hi guys..

i have so doubts in my mind and that i want to discuss with you guys... Can i use more then 5/6 fields in a table with datatype of Text as u know Text can store maximu data... ? acutally i am trying to store a very long strings values into the all fields. it's just popup into my mind that might be table structer would not able to store that my amount of data when u use more then 5/6 text datatypes...

and another thing... is which one is better to use as data type "Text" or "varchar(max)"... ?
if any article to read more about these thing,, can you refere to me...

Thanks and looking forward.-MALIK

View 5 Replies View Related

SQL && C# Help On A Button Click!!!

Mar 7, 2008

Hey Guys,
I'm not sure if anyone can help me with this but I am trying to achieve the following:
I have a row (In this case it is information on a fix) and on a button click I am trying to get it to "archive" it.  At the moment I have it so that it it takes the current information and adds it to the archive table adding an archive date.  The thing that I am struggling with is incrementing the version number. So, I need it to (in these steps I think) - Look for existance of the other entires of that ID, look for the version number that is related to the newest date of those knowledgeIDs and then add 1 to it.  If that knowledgeID doesnt exist then add it as one.
My current code is below:
Thanks in Advance =)
C# Codeprotected void Page_Load(object sender, EventArgs e)
{UserName = (string)Session["UserName"];
Label4.Text = UserName + " Is Current Logged In";UserType = (string)Session["UserType"];if ((Session["UserName"] != null) & (UserType == "Helpdesk"))
{Response.Redirect("Accessrights.aspx");
}else if (Session["UserName"] == null)
{Response.Redirect("Login.aspx");
}
FixName = "default";Description = "default";File = "default";
ADate = myCalendar.TodaysDate.ToShortDateString();
AddDate = Convert.ToDateTime(ADate);myConnectionString = "Data Source=.\SQLEXPRESS;AttachDbFilename=C:\inetpub\wwwroot\HOF\App_Data\HOF.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True;";
}protected void Button1_Click(object sender, EventArgs e)
{SqlConnection myConnection = new SqlConnection(myConnectionString);
try
{
FixName = TextBox1.Text;
 SqlCommand myCommand = new SqlCommand("select * from Knowledge WHERE FixName like '%" + FixName + "%'", myConnection);
myConnection.Open();SqlDataReader myReader = myCommand.ExecuteReader();if (myReader.HasRows)
{while (myReader.Read())
{
TextBox1.Text = myReader["FixName"].ToString();TextBox2.Text = myReader["Description"].ToString();
File = myReader["Location"].ToString();if (File != null)
{
TextBox3.Text = File;
}
else
{TextBox3.Text = "There is no script avaliable";
}KnowledgeID = myReader["KnowledgeID"].ToString();Add = myReader["DateAdded"].ToString();
}
myConnection.Close();
}
else
{TextBox1.Text = FixName + "Does not Exist. Please try again.";
}
}catch (Exception ex)
{
myConnection.Close();
}
try
Description = TextBox2.Text;File = Convert.ToString(FileUpload1.FileName);if (CheckBox1.Checked == true)
{SAPPS = "True";
}
else
{SAPPS = "False";
}
{SqlCommand mycommand2 = new SqlCommand("INSERT INTO Knowledge (FixName, Description, Location, DateAdded, DateArchived, Version, KnowledgeID) SET ('" + FixName + "','" + Description + "','" + File + "','" + Add + "','"+AddDate+"','" + SAPPS + "','"+I NEED A VALUE HERE+"','"+KnowledgeID+"')", myConnection);SqlDataAdapter myDataAdapter = new SqlDataAdapter(mycommand2);
sa = mycommand.ExecuteNonQuery();
myConnection.Close();
}catch (Exception ex)
{
myConnection.Close();
}
}
 

View 2 Replies View Related

Web Form Button ?

Sep 24, 2004

I need to make a query to a SQLserver db passing values from a dropdownlist and two text boxes as my criteria. Now if nothing is selected and the button is pressed, I would like to return everything that is part of my Select statement. I am having trouble making my sql statement work.

Im sending you my code as an attachment. I've put * around the area i really need help with.

Even if you could just point me in the right direction as to where to look for a good web forms book using VB.NET and ASP.NET I would really appreciate it.

Thanks,

Jose
AIM- RangerBud249
Yahoo- RangerBud249


Imports System.Data.OLEDB
Imports System.Data
Imports System.Data.SqlClient
Public Class Test
Inherits System.Web.UI.Page
Public dbConn As SqlConnection
Public da As SqlDataAdapter
Protected WithEvents txtStart As System.Web.UI.WebControls.TextBox
Protected WithEvents txtEnd As System.Web.UI.WebControls.TextBox
Protected WithEvents Calendar1 As System.Web.UI.WebControls.Calendar
Protected WithEvents Label1 As System.Web.UI.WebControls.Label
Protected WithEvents img_cal1 As System.Web.UI.WebControls.ImageButton
Protected WithEvents img_cal2 As System.Web.UI.WebControls.ImageButton
Public ds As DataSet

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'the TailNumber is the first thing that will load
If Not Page.IsPostBack Then
lstAircraft.DataSource = GetAircraft() 'this function will load the Tail Numbers
lstAircraft.DataValueField = "TailNumber"
lstAircraft.DataTextField = "TailNumber"
lstAircraft.DataBind()
End If
End Sub

Function GetAircraft() As System.Data.DataSet
'this function will load the Tail Numbers
Dim connectionString As String = "connection info"
Dim dbConnection As System.Data.IDbConnection = New System.Data.SqlClient.SqlConnection(connectionString)

Dim queryString As String = "SELECT [Aircraft].[TailNumber] FROM [Aircraft]"
Dim dbCommand As System.Data.IDbCommand = New System.Data.SqlClient.SqlCommand
dbCommand.CommandText = queryString
dbCommand.Connection = dbConnection
Dim dataAdapter As System.Data.IDbDataAdapter = New System.Data.SqlClient.SqlDataAdapter
dataAdapter.SelectCommand = dbCommand
Dim dataSet As System.Data.DataSet = New System.Data.DataSet
dataAdapter.Fill(dataSet)

Return dataSet
End Function

******************************************************************************************************************
this is the area I really need help with

Sub btm_Submit_Click(ByVal sender As Object, ByVal e As EventArgs)
Dim connectionString As String = "connection info"
Dim dbConnection As System.Data.IDbConnection = New System.Data.SqlClient.SqlConnection(connectionString)
dbConnection.Open()
dbConnection.Close()
Dim selection As String
Dim startTime As String
Dim landingTime As String
Dim flights As String

Dim selString As String = "SSELECT AircraftID, fromLocation, startTime, toLocation, landingTime, ID, Filename, VSU, local_1 FROM Flights, tbl_FileNames, tbl_VSU"

Dim commandString As String = "SELECT [Flights].AircraftID, [Flights].fromLocation, [Flights].startTime, [Flights].toLocation, [Flights].landingTime, [tbl_FileNames].ID, [tbl_FileNames].Filename, [tbl_FileNames].VSU, [tbl_FileNames].local_1 FROM Flights, tbl_FileNames, tbl_VSU"

selection = "where " & Me.lstAircraft.SelectedValue.ToString & " " & startTime = Me.txtStart.Text & " " & Me.txtEnd.Text = landingTime & " " & [Flights].[ID] = [tbl_VSU].[flight_id]) AND [tbl_VSU].[filename_id] = [tbl_FileNames].[ID]"
If Me.txtStart.Text <> "" Then
selString = selString & selection
End If
Session("SelStr") = selString

Dim dbCommand As New OleDbCommand(commandString, dbConnection)

DataGrid1.DataSource = GetFlights(lstAircraft.SelectedValue)
DataGrid1.DataBind()
End Sub
*********************************************************************************************************************

Function GetFlights(ByVal ID As Integer) As System.Data.DataSet
Dim connectionString As String = "connection info"
Dim dbConnection As System.Data.IDbConnection = New System.Data.SqlClient.SqlConnection(connectionString)

Dim queryString As String = "SELECT [Flights].[toLocation], [Flights].[startTime], [tbl_FileNames].[ID], [Flig" & _
"hts].[fromLocation], [tbl_FileNames].[filename], [tbl_FileNames].[Local_1], [Fli" & _
"ghts].[AircraftID], [Flights].[landingTime], [tbl_FileNames].[VSU] FROM [Flights" & _
"], [tbl_FileNames], [tbl_VSU] WHERE (([Flights].[ID] = [tbl_VSU].[flight_id]) AN" & _
"D ([tbl_VSU].[filename_id] = [tbl_FileNames].[ID]))"
Dim dbCommand As System.Data.IDbCommand = New System.Data.SqlClient.SqlCommand
dbCommand.CommandText = queryString
dbCommand.Connection = dbConnection

Dim dataAdapter As System.Data.IDbDataAdapter = New System.Data.SqlClient.SqlDataAdapter
dataAdapter.SelectCommand = dbCommand
Dim dataSet As System.Data.DataSet = New System.Data.DataSet
dataAdapter.Fill(dataSet)

Return dataSet
End Function

Private Sub img_cal1_Click(ByVal sender As System.Object, ByVal e As System.Web.UI.ImageClickEventArgs) Handles img_cal1.Click
'this will make the calendar for start visible when clicked and not visible if clicked again
Session("Cal1") = True
Session("Cal2") = False
Me.Calendar1.Visible = True
End Sub


Private Sub img_cal2_Click(ByVal sender As System.Object, ByVal e As System.Web.UI.ImageClickEventArgs) Handles img_cal2.Click
'this will make the calendar for end visible when clicked and not visible if clicked again
Session("Cal2") = True
Session("Cal1") = False
Me.Calendar1.Visible = True

End Sub

Private Sub Calendar1_SelectionChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Calendar1.SelectionChanged
'this will put the date selected in my text box as a short date
If Session("Cal1") = True Then
txtStart.Text = Calendar1.SelectedDate.ToShortDateString
Session("Cal1") = False
ElseIf Session("Cal2") = True Then
txtEnd.Text = Calendar1.SelectedDate.ToShortDateString
Session("Cal2") = False
End If
Me.Calendar1.Visible = False

End Sub


End Class

View 1 Replies View Related

Back Button

Jun 2, 2008

Hello.
When I'm useing a report in reportViewer I have a "back button" in the the viewer which let me go back to my parent report after jumping to another report.

I wanted to make a bigger button like that on the report so I tried to simulate it by creating my own textback and use a javascript to go back one page.

This doesn't work since the javascript doesn't work as well as the built in bottun.
Is there a way to simulate this button any way?

Thanks.

View 2 Replies View Related

Where's The Start Button?

Jan 30, 2008



I just installed and registered SQL Server Express but I don't see any shortcuts or Start -> Programs links. I found the new folder it created C:Program FilesMicrosoft SQL ServerMSSQL.2 and I tried to run this file:

C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLBinnsqlservr.exe


Nothing happens. Nada. Do I have to restart my computer?

PS: Is there a QuickStart tutorial on using its Reporting Services?

View 5 Replies View Related

Click Button?

Oct 15, 2007



Hi everyone, Im using SSRS 2000 and I was wondering is there a way to create a click button??? I have 2 reports linked with hyperlinks but I wanted to make it look more presentable. So, instead of just clicking on the words, I want them to click the button.

Thanks in advance,

Abner

View 3 Replies View Related

Print Button

Feb 1, 2006

Print button is disabled for some users. Don't know why it is doing so? Works fine for most of the users in the same group.

Any help is much appreciated.



SQL SERVER Reporting Services 2000

Win XP

View 10 Replies View Related

Print Button

Aug 8, 2006

I have a web application with a stand alone report. When I put the ReportViewer in the webform I can see every reports in the project. The problem is that I can't see the print report button...

If I indicate that the report is a "Server Report" instead a local report the Print Report appear, but a need a "Local Report" not a "Server Report" How can i solve that.

Thank you.

View 3 Replies View Related

Search Button

Apr 14, 2008



Hi There,

I wanted to add a search button to my report where by it would only be visible after the report was run by the user and then the user could search on a particular field(Called Synopsis) for a value, ex QREF12345. I don't want the user to enter QREF, just the number. How could this be coded?? Also, are there any good sites available with code snippetts available?

Thanks,

Rhonda

View 1 Replies View Related

Reset-button

Nov 15, 2006

I want a reset-button which clear my formular....

I have the following code in mypage.aspx.vb:

Sub Reset(ByVal sender As Object, ByVal e As System.EventArgs)

Me.Server.Transfer("Mypage.aspx") 'reloads the page without postback?

End Sub

And a button on mypage.aspx:

<asp:Button ID="Button2" OnClick="Reset" runat="server" Text="Rensa" />



But when I click the button....the validation-controls executes before...so instead for "clearing" the page (reload it without postback) the validation-messages shows that I have forgott to write in som textboxes....

What should I do?

View 1 Replies View Related

OK Button Not Working...

Sep 29, 2005

I am trying to get MSSQL Reporting Services working. I have used it before, but now I have the opportunity to get the software entrenched in my organization. I installed the app and it opens up, but when I try to create a new folder the software will not allow the OK choice. I can cancel, but I need to choose OK.

View 16 Replies View Related

Changing The Source Wth A Button

Feb 4, 2007

Hi,
I have this Gridview in which I show attendees to a course (per course)
In the same gridview I want to be able (by clicking a button) to show all attendees to all courses simply by leaving out a part of the SQL;
WHERE Eventid = @eventid (resulting in all attendees no matter what course)
In other words how can I alter the selectcommand of the SQLDataSource?
Seems simple, but can't hack it.
Thanks in advance,
Lx 

View 3 Replies View Related

How To Assign SQL Query To Button In Asp.net 2.0

May 24, 2007

Hi
                  My webpage contain three dropdown box and one button. One dropdown to choose hospital_id, second dropdown to choose project_id and third dropdown to choose version_no .After choosing these three and when the button is clicked i want to run this sql query
INSERT INTO  version(project_id,hospital_id,date_created,comments) SELECT project_id,hospital_id,date_created,comments FROM version where version_no=@version_no and project_id=@project_id and hospital_id=@hospital_id.
Just i need the code in asp.net 2.0 , VB , when the button is clicked the above query should run and the parameters (values) should take from dropdown box.
Could anyone please send the solution for the above problem.

View 1 Replies View Related

Executing SQL With A Button Click.

Dec 25, 2007

I feel like it must be easy and I'm missing something.  Maybe I'm going the wrong way about it too.  Basically I've written an append query that needs parameters, but I have no idea how to actually execute it.  I'm coming from building apps in MS Access where all of this is really easy.  I'm really enjoying learning some things, and did my first MS SQL trigger event tonight, which worked great.  I though using a trigger may be an option here, but I need to control the "when" of this append a little more carefully and can't rely on an automated event. I can manually execute the query and it works, but have a button I could press on a form, with the queries on that form would be ideal.  I'm basically moving partial data from one table to another. Any help?  Again, this seems like it "should" be easy, but I'm not finding info on it.  Please talk slowly, as again, I'm coming from Access. 

View 5 Replies View Related

SqlDataSource, GridView && A Button

Jan 12, 2008

hi .. i have a SqlDataSource, GridView & a Button ..  i want to increase the condition in the "SelectCommand" below by one everytime i click the button .. i mean to be like that ID < 8 instead of ID < 7
so, the GridView will show 7 ID's instead of 6 .. and it will increase everytime i hit the button<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:connectionstring %>"
SelectCommand="SELECT * FROM [table1] WHERE ID < 7">
</asp:SqlDataSource>
 

View 4 Replies View Related

Delete Button Problem

Apr 3, 2008

Can someone please help with my problem.  I have a button that should delete a record using a SP, the SP works fine but I’m getting this error message when I load the page“CS0118: 'System.Web.HttpRequest.QueryString' is a 'property' but is used like a 'method'â€?  - “ptimesheetid.Value = Request.QueryString("timesheetid");â€? 
Please find the code for my button below, any help will be greatly appreciated.
 protected void DelTS(object sender, EventArgs e)
{
System.Data.SqlClient.SqlConnection objConn = new System.Data.SqlClient.SqlConnection();
objConn.ConnectionString = "Data Source=SQL03;Password=rdbx1;User ID=rdbx1;Initial Catalog=pronet_ts";
objConn.Open();
System.Data.SqlClient.SqlCommand objCmd = new System.Data.SqlClient.SqlCommand("delete_timesheets", objConn);
objCmd.CommandType = System.Data.CommandType.StoredProcedure;
System.Data.SqlClient.SqlParameter ptimesheetid = objCmd.Parameters.Add("@timesheetid", System.Data.SqlDbType.Int);

ptimesheetid.Value = Request.QueryString("timesheetid");

objCmd.ExecuteNonQuery();

objConn.Close();



}
 

View 3 Replies View Related

Permissions / Apply Button

Aug 20, 1999

Is anyone else having trouble with the Apply button under the permissions tab?
I can change permissions, click apply, the changes are shown, but when I access the database, the changes arn't made. If I close the permissions windows and re open the changes arn't made.

Will SP1 fix this?(it's not listed in the fix text file)

View 2 Replies View Related

How To Add Record Thru Command Button In Adp.

Feb 21, 2005

Hi,

In access database project where my tables are linked from MSSQL server, how can I add record from the FORM itself using command button. Bcz it is not like mdb files in access that you can just drag a command button onto the form and take an action like add, delete, print or find rec. I just came to know it from immediate window using following SQL line;

Docmd.RunSql "Insert........

This is ok but how it could be done thru a command button on FORM.

Thanks in advance.

With kind regards,
Ashfaque

View 4 Replies View Related

BIDS Undo Button

Apr 9, 2008

How come Undo button does not work? Thanks.

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved