CodeVerge.Net Beta


   Explore    Item Entry    Members      Register  Login  
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML

Free Download:




Zone: > NEWSGROUP > Asp.Net Forum > starter_kits_and_source_projects.portal_starter_kit Tags:
Item Type: NewsGroup Date Entered: 7/21/2004 6:01:49 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 2 Views: 15 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
3 Items, 1 Pages 1 |< << Go >> >|
americanvintner
Asp.Net User
problem with page7/21/2004 6:01:49 AM

0/0


Edited by SomeNewKid. Please post code between <code> and </code> tags.



I have found this forum to be invaluable in resolving my issues with my portal in the past, but now I am befuddled. I have simple page that I load in the left pane. I have a textbox, button and data grid on it. When I click the button it does nothing. Yet when I use the same code in another project (where I test my code) it works fine. What am I doing wrong? Here is the code:

private void Button_Click(object sender, System.EventArgs e)

{
SqlConnection conn = new SqlConnection("data source=localhost; initial catalog=portal;" + "integrated security=True; persist security info=True;");

SqlDataAdapter da = new SqlDataAdapter();
da.SelectCommand = new SqlCommand();
da.SelectCommand.Connection = conn;
da.SelectCommand.CommandText = "ValidZipCode";
da.SelectCommand.CommandType = CommandType.StoredProcedure;

string input = TextBox.Text.ToString();

SqlParameter param = new SqlParameter("@ZipCode", SqlDbType.Int, 4);
param.Direction = ParameterDirection.Input;
param.Value = input;

da.SelectCommand.Parameters.Add(param);

DataSet ds = new DataSet();
da.Fill(ds, "CityName");
dg.DataSource = ds;
dg.DataMember = "CityName";
dg.DataBind();
}


Thanks in advance
wunderkinder
Asp.Net User
Re: problem with page7/21/2004 8:54:26 PM

0/0

Does the button have a handler assigned to the click event?
Jared Livingston
MrLivingston.com - Livingston Family Website

Test/Demo site - moonmark.com
americanvintner
Asp.Net User
Re: problem with page7/22/2004 6:22:59 AM

0/0

Ok here is the html code I used on my practice .aspx page:

<%@ Page language="c#" Codebehind="Default.aspx.cs" AutoEventWireup="false" Inherits="PracticeWebSite.WebForm1" %>
<%@ Register TagPrefix="uc1" TagName="ZipCode" Src="ZipCode.ascx" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
HEAD>
<title>WebForm1</title>
<meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" Content="C#">
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
</HEAD>
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<uc1:ZipCode id="ZipCode1" runat="server"></uc1:ZipCode>
</form>
</body>
</HTML>

and this is the html code I used on the .ascx page:

<%@ Control Language="c#" AutoEventWireup="true" Codebehind="ZipCode.ascx.cs" Inherits="PracticeWebSite.ZipCode"%>
<asp:TextBox id="TextBox" Font-Size="X-Small" runat="server" Width="72px" MaxLength="5"></asp:TextBox><br>
<asp:Button id="Button" runat="server" Text="Click" Width="56px"></asp:Button><br>
<br>
<br>
<asp:DataGrid ID="dg" Runat="server" BorderColor="Tan" BorderWidth="1px" BackColor="LightGoldenrodYellow"CellPadding="2" GridLines="None" ForeColor="Black" Font-Size="Smaller" ShowHeader="False">
<SelectedItemStyle ForeColor="GhostWhite" BackColor="DarkSlateBlue"></SelectedItemStyle>
<AlternatingItemStyle BackColor="PaleGoldenrod"></AlternatingItemStyle>
<HeaderStyle Font-Bold="True" BackColor="Tan"></HeaderStyle>
<FooterStyle BackColor="Tan"></FooterStyle>
<Columns>
<asp:ButtonColumn Text="Select" ButtonType="PushButton" HeaderText="Select" CommandName="Select"></asp:ButtonColumn>
</Columns>
<PagerStyle HorizontalAlign="Center" ForeColor="DarkSlateBlue" BackColor="PaleGoldenrod"></PagerStyle>
</asp:DataGrid>

Very simple and it works.

When I duplicate the code in my portal the page appears with the text box and button. When I click the button the datagrid does not appear. It looks like it is trying to work but there is no error and I just don't get any results (like I do on the practice site.) Is there anything with the built in module user security settings that might not allow this page from working?

Again thanks.....
3 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
What is Mathematics?: An Elementary Approach to Ideas and Methods Authors: Richard Courant, Herbert Robbins, Ian Stewart, Pages: 566, Published: 1996
Problem Page: A Play Authors: Julia Donaldson, David Mostyn, Pages: 32, Published: 2000
Problem Solving and Comprehension Authors: Arthur Whimbey, Jack Lochhead, Pages: 387, Published: 1999
Schaum's Outline of Theory and Problems of Probability and Statistics Authors: Murray R. Spiegel, John J. Schiller, R. Alu Srinivasan, Pages: 408, Published: 2000
Mac OS X: The Missing Manual Authors: David Pogue, Pogue, Safari Tech Books Online, Safari Tech Books Online, Pages: 712, Published: 2002
Mathematical Modelling: A Tool for Problem Solving in Engineering, Physical, Biological, and Social Sciences Authors: D. N. P. Murthy, N. W. Page, Ervin Y. Rodin, Pages: 339, Published: -1
The Dog Whisperer: A Compassionate, Nonviolent Approach to Dog Training Authors: Paul Owens, Norma Eckroate, Pages: 289, Published: 2007
Problem Solving Authors: Ray Page, John Poole, Roland Clarke, National Centre for School Technology (Great Britain), Pages: 112, Published: 1982

Web:
ProblemPages.co.uk - The UK's online problem pages magazine. ProblemPages.co.uk no longer accepts e-mail problems - we just couldn't keep up! ... Getting Help - Thoughts on how to find help with any problem. ...
Problem advice page.Real answers for real personal problems.Find ... Advice & help for many problems of life. Don't suffer - we are here to listen, share & care. Email counsel available. Find advice & answers to hurts, ...
Synoptic Problem The Synoptic Problem Home Page surveys proposed solutions and provides a clearing-house for materials related to its resolution. ...
Dear Deidre | Sun Agony Aunt | The Sun |Deidre If you have a similar problem and would like Deidre’s help CLICK HERE. Advertisement ... E-mail this page to a friend · Print this page ...
The Permission Problem: Financial Page: The New Yorker The Financial Page. The Permission Problem. by James Surowiecki August 11, 2008 ... Or take a problem that bedevils the oil-and-gas industry. ...
The Chrysler Products' Problem Web Page Help for consumers who have had problems of any and all sorts with Chrysler products.
Traveling Salesman Problem The Traveling Salesman Problem is one of the most intensively studied problems in computational mathematics. These pages are devoted to the history, ...
John's Problem Tracking Page This is the start of a modest collection of references to problem tracking systems. I first publically referred to this page in my article On Reliability ...
HairyLunch's Creative Problem Solving Page - Wood Offers advice on studying balsa wood to ensure good pieces.
Synoptic Problem Website ... My Sites: Synoptic Problem Website: Old Synoptic Problem Home Page ... The Synoptic Problem Website surveys proposed solutions and provides a ...

Videos:
Mustache on People's Court Defendant Joe Somar, of the band 'The Fugue', on People's Court, explaining why his life is hard. "Mustache."
Gears and the Mashup Problem Google Tech Talks September, 20 2007 ABSTRACT Mashups are the most interesting innovation in software development in decades. Unfortunately, the br...
Zero Point Energy - the Answer or the Problem Paula Gloria goes to Panama City to interview Dr. John Shelbourne a Mechanical Engineer who has worked seriously with perpetual energy devices. The f...
Alice D In Wonderland - Time Problem Label: Be.S.T. Records Catalog#: PAGE 002 Format: Vinyl, 12" Country: Netherlands Released: 1991 Genre: Electronic Style: House, Techno N...
Stoichiometry: mass / mole problem with Mr. D at Arcola High School This is an example of a mass / mole stoichiometry problem. It comes from page 307 of our textbook.
Technical Problem - Is it just me? - Please let me know. I'm having a problem. My page that shows videos recently uploaded by people that I'm subscribed to, only shows the 10 most recent. In the past I coul...
noisy boy & problem page last tune @ dissident 6th october last tune of the night 6am at Clockwork bristol
Campagnolo Ultra Torque Problem? -RogueMechanic A short video straight from the RogueMechanic shop showing horizontal movement in the Campagnolo Ultra Torque system. Look for part 2 which shows wh...
Wake Up Call - Remastered Edition (NEW) - New World Order Documentary - 2008 New remastered version of Wake Up Call...See my MySpace page (www.myspace.com/johnnada80) for high quality DVD's and torrent links... Some of the top...
Its a big problem How i turn the page !!!!! Befor You read learn how to turn the page-funny video . Enjoy Watching




Search This Site:










dnn installation problem

dnn3.0.8 on godaddy hosting

problem with the bin dir

visual studio gone mad!

hosting speed comparison example - wh4l vs powerdnn

portal comments - per user

can't insert variables into my table?

dynamic treeview control in master page

bug: sitemapnodecollection(sitemapnodecollection) constructor fails

web service security, impersonation

modified personal_add.sql

set focus to user name text box in login control?

help please

oresult.getdirectoryentry().properties("samaccountname").value does not match string value

dotnetnuke custom module testenvironment ?

master page in different directory

multiple blog login

how to create web project in remote iis with visual studio.net 2005

asp.net cache object problem

aspnetdb.mdf

how to get the "remember me" function to work in a custom membership provider

dnn only sending email to domain email addresses

delected selected node from treeview

getting a webpart's id not to show up

alternate links module

treeview onclick problem

visual studio express upgrade to visual studio 2005 pro

add access control to modules (2nd time)

roles not working

what happened to copylocal?

 
All Times Are GMT