Checking if a dataset is empty


I use a session variable to store the data filled in three form pages registration. On every page I create a dataset with a table object in it and then I assign the dataset to the session.

If the user decides going back to the previous form page I want to refill all the form fields with the data stored in the session, now I am trying to do it thus on the second page: (in the case of user comes from the third page)

CODESub Page_Load(sender As Object, e As EventArgs)
\tIf Not IsPostBack Then

\t\tDim ds2 As DataSet
\t\tds2 = CType(Session("UserData"), DataSet)
\t\t\t\tIf Not isNothing(ds2.tables(0).rows(0)) then

\t\t\t\t\t\t\tname.Text() = ds2.Tables(0).rows(0).Item("companyName").ToString
\t\t\t\t\t\t\tstate.SelectedValue = ds2.Tables(0).rows(0).Item("State").ToString\t\t
\t\t\t\t\t\t\tcity.SelectedValue = ds2.Tables(0).rows(0).Item("city").ToString\t\t
\t\t\t\t\t\t\t...\t\t

\t\tEnd If

\tEnd If

End Sub
But I receive this error just when I come normally from the first page to the second:
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Line 73: state.SelectedValue = ds2.Tables(0).rows(0).Item("State").ToString

I don t understand this error because the subroutine says that only set the values from the session to the form fields if the data exists in the dataset: 'If Not isNothing(ds2.tables(0).rows(0)) then'. And if I come from the first page the dataset of the second page it doesn t exists yet...

Somebody knows what is the problem


On the first form page:
CODESub userData(Sender As Object, e As EventArgs)

\tDim ds As New DataSet()
\tDim dt As New DataTable()
\tdt.columns.add("Mail")
\tdt.columns.add("Password")
\tdt.columns.add("userType")
\tdt.columns.add("zipCode")
\tdt.columns.add("companyName")
\tdt.columns.add("State")
\tdt.columns.add("City")
\t...

Dim row As DataRow
\trow = dt.NewRow()
\trow.Item("Mail") = mail.Text
\trow.Item("Password") = password.Text
\trow.Item("userType") = userType.SelectedItem.Value
\trow.Item("zipCode") = zip.Text
\t
\tdt.Rows.Add(row)
\tds.tables.add(dt)
\tSession("UserData") = ds

End Sub
On the second form page:
CODESub userData(Sender As Object, e As EventArgs)

\tDim ds2 As DataSet
\tds2 = CType(Session("UserData"), DataSet)\t

\tDim row As DataRow
\trow = ds2.Tables(0).Rows(0)
\trow.Item("companyName") = name.Text
\trow.Item("State") = state.SelectedItem.Value
\trow.Item("City") = city.SelectedItem.Value
\t...

\tSession("UserData") = ds2

\tresponse.Redirect("Form3_NewUser.aspx")

End Sub
Thank you
Posted On: Wednesday 2nd of January 2013 01:43:42 AM Total Views:  549
View Complete with Replies

RELATED TOPICS OF ASP.NET PROGRAMMING LANGUAGE




too many arguments specified????

I am getting this wrror. I am not sure why....Procedure or function GetSingleQuoteSendQuoteInfo has too many argumentsspecified.\t\t\t\tPublic Function GetQuoteSendQuoteInfo(ByVal QuoteCookieID AsString) As Integer\t\t\t\t\t\t' Create Instance of Connection and Command Object\t\t\t\t\t\tDim myConnection As NewSqlConnection(ConfigurationSettings.AppSettings("connectionString"))\t\t\t\t\t\tDim myCommand As New SqlCommand("GetSingleQuoteSendQuoteInfo",myConnection)\t\t\t\t\t\t' Mark the Command as a SPROC\t\t\t\t\t\tmyCommand.CommandType = CommandType.StoredProcedure\t\t\t\t\t\t' Add Parameters to SPROC\t\t\t\t\t\tDim parameterQuoteCookieID As New SqlParameter("@QuoteCookieID",SqlDbType.NVarChar, 50)\t\t\t\t\t\tparameterQuoteCookieID.Value = QuoteCookieID\t\t\t\t\t\tmyCommand.Parameters.Add(parameterQuoteCookieID)\t\t\t\t\t\tDim parameterID As New SqlParameter("@id", SqlDbType.Int, 4)\t\t\t\t\t\tparameterID.Direction = ParameterDirection.Output\t\t\t\t\t\tmyCommand.Parameters.Add(parameterID)\t\t\t\t\t\t' Open the database connection and execute the command\t\t\t\t\t\tmyConnection.Open()\t\t\t\t\t\tmyCommand.ExecuteNonQuery()\t\t\t\t\t\tmyConnection.Close()\t\t\t\t\t\t' Return the datareader\t\t\t\t\t\tReturn CInt(parameterID.Value)\t\t\t\tEnd FunctionSP......CREATE PROCEDURE GetQuoteSendQuoteInfo(@QuoteCookieID nvarchar(50),@Expr1 nvarchar(20) OUTPUT)ASSELECT@Expr1 = COUNT(*)FROMtempQuoteINNER JOINtempQuoteDetail ON tempQuote.tempQuoteID = tempQuoteDetail.tempQuoteIDWHEREtempQuoteQuidID = @QuoteCookieIDGO
VIEWS ON THIS POST

187

Posted on:

Monday 12th November 2012
View Replies!

uping Ajax Update Panel

I have three panels on a page: panel_A has a gridView gv1 with PageSize = "5" OnRowCommand = "LoadCompanyInfo" OnPageIndexChanging="gridView_PageIndexChanging1" Panel_B has gridview gv2 with PageSize = "5" OnRowCommand = "SelectEmployee" OnPageIndexChanging="gridView_PageIndexChanging2" Panel_C has labels CompanyID, CompanyName, EFirst, ELast and EMiddle. Panel_A panel_B and panel_C are in an update panel. Each row in gv1 is a LinkButton, so if I click on a row, it runs a method 'LoadAccount' which updates the labels in panel_C and also populates the gridview on panel_B. This part is working fine, when I click on a row in gv1, it updates the labels text in Panel_C and populates gv2 in panel_B. I am having the following issues: 1.When I click on a row in gv2, it makes the labels text in panel_C blank and gv2 also becomes blank, shows EmptyDataText. I expect it to just update EFirst, ELast and EMiddle. in panel_A. 2. When I click on the next page no on gv1 it fires LoadCompanyInfo method first and then goes in the gridView_PageIndexChanging1 event. I expect it to go in the gridView_PageIndexChanging1 event only and show next page in gv1 and not in LoadCompanyInfo , because I am just clicking on page no 2 not row 2. 3. gv1 refreshes on a timer event OnTick = Timer_Tick, and it clears off data in panel_B and panel_C. I want it to just update panel_A. I guess I will have to set up nested Update panels to accomplish this. I would appreciate if I can get help on setting these nested update panels on this page to accomplish the above 3 issues. Thank you.
VIEWS ON THIS POST

142

Posted on:

Friday 16th November 2012
View Replies!

problem with the reference to the AjaxControlToolkit

I have a problem with a project I am developing in VS 2008. I added a reference to the AjaxControlToolkit in my project. I then go into the html source to add the ajax control to my page and it is giving me error messages saying that "ModalPopupExtender is not a known element" I have a statement to register the assembly at the top of the page. Has anybody else had this problem too. I would appreciate any help with issue
VIEWS ON THIS POST

190

Posted on:

Saturday 24th November 2012
View Replies!

Email Contact Form

Alright, so I have this contact form and everything shows up just fine, and it acts like it sends email, but I am not recieving anything... I am not sure what is going on - so help is appreciated. Here is my code: protected void SendMail(Object sender, EventArgs e) { MailMessage mail = new MailMessage(); mail.From = new MailAddress("valid@emailAddress.com"); mail.To.Add(tbEmail.Text.ToString); mail.Subject = tbSubject.Text.ToString; mail.IsBodyHtml = true; mail.Body = "Name: " + tbName.Text.ToString + ""; mail.Body += "Operating System: " + OSDropDown.Text.ToString + ""; mail.Body += "Application Name: " + appDropDown.Text.ToString + ""; mail.Body += "Question/Comment:      " + tbBody.Text.ToString + ""; SmtpClient smtp = new SmtpClient(); smtp.Host = ; smtp.Send(mail); } protected void Reset(object s, EventArgs e) { } ----Select One---- Windows 7 32-Bit Windows 7 64-Bit Windows Vista 32-Bit Windows Vista 64-Bit Windows XP 32-Bit Windows XP 64-Bit ----Select One---- Deck Designer (Do-It-Yourself) Fence Designer (Do-It-Yourself) Garage Designer (Do-It-Yourself) Post Frame Designer (Professional) Deck Designer (Professional) Fence Designer (Professional) Garage Designer (Professional) Post Frame Designer (Professional)
VIEWS ON THIS POST

224

Posted on:

Saturday 24th November 2012
View Replies!

Ajax MaskedEditExtender not displaying mask

Okay, this is really throwing me and making me feel crazy. I'm sure I'm missing something dumb. I'm building an account registration form, and I want to put a mask on the phone number textbox, i.e. XXX-XXX-XXXX. I'm using the AjaxToolkit MaskedEditExtender and MaskedEditValidator. The validator actually does display it's error message, but there is no mask on the textbox. I have the toolkit registered in the web.config, and everything else I'm using from it works fine. I did notice that I can't drag-and-drop the maskededitextender into the form, which seems odd: the maskededitvalidator dropped in fine. Here's the table cell that has the phone number controls: I'm really at a loss as to what's going on, and I'm beginning to wonder if it's an issue with the page or the toolkit assembly, or maybe asp.net just doesn't like me anymore.
VIEWS ON THIS POST

231

Posted on:

Tuesday 27th November 2012
View Replies!

IIS6 Not configured for .Net - Framework is installed

A client of mine has Windows Server 2003..Net Framework 1.1 is installed.IIS6 is not configured to run .Net apps, the ISAPI mappings have no .aspx or .ascx and all the other files types for .net.In IIS6 is there a way to configure IIS without having to uninstall the .net framework an re-installing it
VIEWS ON THIS POST

300

Posted on:

Tuesday 27th November 2012
View Replies!

Fill DropDownList in EditItemTemplate

I'm trying to programatically fill a dropdownlist that is an the EditItemTemplate of a DataList. I've tried to bind the data in the Edit Command event handler, but this handler only has access to controls in the ItemTemplate, not the EditItemTemplate. Does anyone know how and when to bind the dropdownlist
VIEWS ON THIS POST

204

Posted on:

Tuesday 27th November 2012
View Replies!

Textbox in ListBox/DropDownList possible?

Is it possible to have a textbox situated at the bottom of an ASP.NET DropDownList (runat=server) I figured this would be a good way to allow entry of text fields in a "Other" textbox inside the DropDownList when the listbox entries do not show what is needed
VIEWS ON THIS POST

188

Posted on:

Tuesday 27th November 2012
View Replies!

Summing a datagrid column???

I've got a dataset and i bound to a datagrid. in this datagrid there is 17 columns. I want to summing a datagrid columns and show the result in footer. i tried the code i write below but i couldn't get the result:(int x1 =e.Item.ItemIndex;int x2 = DataGrid1.Items[x1-1].DataSetIndex;string name = ds.Tables[0].Columns[x2].ColumnName;for (int i=0 ;i < e.Item.Cells.Count;i++){if(name!=null && name.CompareTo("KolonOne")!=0){if (e.Item.ItemType== ListItemType.Item ||.Item.ItemType== ListItemType.AlternatingItem){Sum[3] += Convert.ToInt64(DataBinder.Eval(e.Item.DataItem,"GVM")); e.Item.Cells[3].Text+=e.Item.ItemType.ToString();}else if (e.Item.ItemType== ListItemType.Footer){e.Item.Cells[3].Text = String.Format("{0:#,###}",Sum[3]);}}}
VIEWS ON THIS POST

179

Posted on:

Tuesday 1st January 2013
View Replies!

Query to Advantage DB is timing out

I have an Advantage (yeah right) db that I'm trying to connect and query to but when I run it just times out. Below is my connection string in case I'm doing it wrong
VIEWS ON THIS POST

189

Posted on:

Tuesday 1st January 2013
View Replies!

Price compare site

I need some advice on how-to do a project. What I'm doing is a price compare book site for a college. I'm not sure on how to retrieve the data from other sites and populate a table. I know some sites will give me data access to their inventory, but how do I put all the data together Into an XML file or a dataset, or something else I have never done this before, so any suggestions would be helpful. It will be like www.isbn.netJim What doesn't kill you makes you stronger.
VIEWS ON THIS POST

109

Posted on:

Wednesday 2nd January 2013
View Replies!

GDI+ Bitmaps, potential canvas(es)

Which controls within ASP.net can contain, and display, a Bitmap object, other than the Response.Outputstream (ie, the page itself)I'm doing some GDI+ drawing on a Bitmap object, which I like to pass to a valid receiver.It would make sense to me that for instance an asp:image can contain this Bitmap, but from what I found, it doesn't look like it.Any ideas
VIEWS ON THIS POST

128

Posted on:

Wednesday 2nd January 2013
View Replies!

Static class vs Session object

Am I correct saying that with ASP.Net, a static class, is basically a single server object, that is active across sessionsMeaning that if I set a value of a static class, all sessions will read the same value. But that means that if one user's session sets this value again with something new, EVERYONE will read this new value, not the old one.What I'm getting at is that I'd like to use something along the lines of: CODEstring text = StaticClassName.SomeValue;I just think it's way cleaner than:CODEstring text = Session["SomeValue"].ToString();Particularly because I don't need the cast with a static method. But, I think the nature of a static class (as I described above) makes this impossible, as it will return 'server' values, instead of 'client' (read: session) variables.Any ideas/suggestions about this
VIEWS ON THIS POST

148

Posted on:

Wednesday 2nd January 2013
View Replies!

Basic Update Question

I am new to asp.net.\tI am creating a .net page which helps update information in an ACCESS database.\tNo I can't upgrade to SQL Server at this time.\tI have a page which I open a open a reader and populate information on a form.\tI want the users to be able update any of the information on the page.\tSome of the data contains text boxes which contain 255 characters.\tSince the page is populated using a query, I have to update the tables individually.\tI have one page I am using.\tI have one Sub to populate data and then was going to call another sub on the onclick update event.\tI have passed a few hidden text boxes to make sure I know which tables passed data from the query.\tIs the only way to update an Access database by using the ExecutNonQuery and creating an update query stringCODE "update table set x='" & txt.text & "' where x='"&hiddentxt.text&"''Also if I want to see if the text box has changed from the original value populated, do I have to store each value in a session variable and see if it has changed before I invoke the update query
VIEWS ON THIS POST

173

Posted on:

Wednesday 2nd January 2013
View Replies!

Create rtf file and display on client.

What I am trying to do is to read an rtf file, replace some text with text from a database (name and address etc), save it to a folder and display it in word on the user's pc.\tTo display the file I am shelling to it using a couple of lines of javascript. The code that reads, modifies and writes the file saves the path to the file in a textbox. This I hoped the javascript could use.Doesn't work. I think that the javascript sub is running before the database related code so there is no path to shell to.Does that seem likely\tIf so, how can I do this I've been struggling away for ages at it. the individual bits work, just the link from the created filename and the javascript on the browser is not working. , OK, I have found your code to do that.If I change from pdf to rtf how does the file end up in ms word I don't understand.
VIEWS ON THIS POST

208

Posted on:

Wednesday 2nd January 2013
View Replies!

Iterate cells in datarowbound event

I'm using conditional formatting in a gridview.\tI want to be able to iterate the cells in that specific row.\tWhat I have below works, but was wondering if there is a collection available so I can use foreach instead.
VIEWS ON THIS POST

122

Posted on:

Wednesday 2nd January 2013
View Replies!

Encoding data securely

i'm coming from a php background where everytime i posted a variable back to the server i would wrap in a function before passing into my sql statement.\tThis allowed me do a replacement for html entities and also a mysql fix to avoid sql injections.With asp.net if i use parameters i avoid any sql injections but i still have problems with html entities.Say in the edit profile area of my site i have a formview which uses 2 way databinding and contains a textbox for the user's first name.\tThen say i wrap the value (when posted back) with Server.HtmlEncode before updating the value in the database.\tIf the user entered
VIEWS ON THIS POST

235

Posted on:

Wednesday 2nd January 2013
View Replies!

Best way of designing this code

The problem ( done in .net1.1).Ive been asked to do some work on a site that uses a number of webservice calls.Currently, there is a web page that kicks off an asynch call to a Web service.The site then redirects to a results page, where it has some javascript that forces it to post back X seconds, where the code on PageLoad checks a database to see if the service has finished executing and has written the result set to the databaseI have been asked to take what is currently being used and extend it, so that on page 1 it makes multiple calls to the webservice, then redirects to page 2 To my mind the whole setup seems inefficient, so I want to propose some changes. Before I do, I need to check my thinking, and get it right in my own head.The simplest approach is to leave the pages as they are, and adding more network traffic (the 5 service calls, then the 5 * n calls to the database until the results are in)But one of the concerns is the amount of traffic that this will cause on the network, and the performance if there are a lot of people using this at the same time (Lots of postbacks triggering lots * 5 database calls)To make it smarter Im thinking of having a manager class that relates the sessionID to a callbackHandler class. When the webservice is complete I will then trigger the database call to pull back that portion of the results, and store that in a dataset in the object.I still get a postback every x seconds, but then all that is doing is forcing the page to rebind to the dataset to display the results, to my mind reducing the traffic to the database significantly.So, can anyone offer any critique of what Im planning to do, and secondly, is there a way I can trigger a page refresh / postback from the server, so I dont even need to have a javascript timer on the client (which seems dodgy to me, as if js is disabled, then the page will never show its results!)I know this may be a bit "moon on a stick", which is why Ive left the option of doing it the current way.K
VIEWS ON THIS POST

245

Posted on:

Wednesday 2nd January 2013
View Replies!

How to launch a ASP page by coding

I am an experienced VB6 developer and I am learning ASP.NET/VB.NET. I am building a Web search interface for our Intranet and I would like to know how to load another ASP page from the code.\tI have a Login page linked to an SQL database to authentify the user when the button 'cmdLogin' is pressed.\tThere is a call to a StoredProc that will return an error message if the credentials are invalid, otherwise it returns 'ALLOWED' Here is the code so far:Protected Sub cmdLogin_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmdLogin.Click\t\t\t\t'Refresh the SQL connection\t\t\t\tsqlLogin.DataBind()\t\t\t\t'Refresh the DataView control\t\t\t\tdetView.DataBind()\t\t\t\tIf detView.Rows(0).Cells(1).Text = "ALLOWED" Then\t\t\t\tElse\t\t\t\t\t\tdetView.Visible = True\t\t\t\t\t\ttxtUserName.Focus()\t\t\t\tEnd If\t\tEnd SubIf it is 'ALLOWED', I need to launch a ASP pag
VIEWS ON THIS POST

141

Posted on:

Wednesday 2nd January 2013
View Replies!

Changes in Web Site Administration Tool raises error

I am a new user of Visual Web Developer 2005 Express Edition.In Web Site Administration Tool, every try to change something on Security tab or Application tab, raises following error message:Attempted to perform an unauthorized operation.\tat System.Security.AccessControl.Win32.SetSecurityInfo(ResourceType type, String name, SafeHandle handle, SecurityInfos securityInformation, SecurityIdentifier owner, SecurityIdentifier group, GenericAcl sacl, GenericAcl dacl)\tat System.Security.AccessControl.NativeObjectSecurity.Persist(String name, SafeHandle handle, AccessControlSections includeSections, Object exceptionContext)\tat System.Security.AccessControl.NativeObjectSecurity.Persist(String name, AccessControlSections includeSections)\tat System.Security.AccessControl.FileSystemSecurity.Persist(String fullPath)\tat System.IO.File.SetAccessControl(String path, FileSecurity fileSecurity)\tat System.Configuration.Internal.WriteFileContext.DuplicateTemplateAttributes(String source, String destination)\tat System.Configuration.Internal.WriteFileContext.DuplicateFileAttributes(String source, String destination)\tat System.Configuration.Internal.WriteFileContext.Complete(String filename, Boolean success)\tat System.Configuration.Internal.InternalConfigHost.StaticWriteCompleted(String streamName, Boolean success, Object writeContext, Boolean assertPermissions)\tat System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.WriteCompleted(String streamName, Boolean success, Object writeContext, Boolean assertPermissions)\tat System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.WriteCompleted(String streamName, Boolean success, Object writeContext)\tat System.Configuration.Internal.DelegatingConfigHost.WriteCompleted(String streamName, Boolean success, Object writeContext)\tat System.Configuration.UpdateConfigHost.WriteCompleted(String streamName, Boolean success, Object writeContext)\tat System.Configuration.MgmtConfigurationRecord.SaveAs(String filename, ConfigurationSaveMode saveMode, Boolean forceUpdate)\tat System.Configuration.Configuration.SaveAsImpl(String filename, ConfigurationSaveMode saveMode, Boolean forceSave)\tat System.Configuration.Configuration.Save(ConfigurationSaveMode saveMode)\tat System.Web.Administration.WebAdminPage.SaveConfig(Configuration config)\tat ASP.security_setupauthentication_aspx.UpdateAndReturnToPreviousPage(Object sender, EventArgs e)\tat System.Web.UI.WebControls.Button.OnClick(EventArgs e)\tat System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)\tat System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)\tat System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)\tat System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)\tat System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)I use network SQL Server 2K. Database ASPNETDB has been created using utility aspnet_regsql.exe, and I changed web.config accordingly.Testing connection to AspNetSqlProvider is OK.What else can be the problemThanx in advance for your suggestions.
VIEWS ON THIS POST

531

Posted on:

Wednesday 2nd January 2013
View Replies!

javascript for maintaining vertical position in code behind

yes, I know I posted this concerning a recent post, but what was with a control I found on the web.I'm now trying it on my own.Here's what I have in my HTML:*****************************************************************For my code behind, I've got the following in the page_load event:If Page.IsPostBack ThenResponse.Write("location.href="" temp_href=""#"""";")End If...tried this too, and no luck for the page_load event:***********************************************************************If Page.IsPostBack ThenDim strScript As StringstrScript = ""strScript = strScript & "location.href=""#"";"strScript = strScript & ""Page.RegisterStartupScript("ClientScript", strScript)End IfAny suggestions are welcome
VIEWS ON THIS POST

141

Posted on:

Wednesday 2nd January 2013
View Replies!

Should I use a panel????

I am fairly new to ASP.NET (actually pretty new to web development)Any way, what I have is a webpage with a ascx at the top for a header, a treeview going down the left hand side of employees, what I am trying to do is when you pick one the employees in the tree their details will show up in on the right hand side of the tree. Using a multiview because the will be different pages of details.When I just put in a multiview their details diplay under the tree not the righthand side.My question is should I put the details on a seperate page and then display that page in a panel.Or what would be the best way to do this...
VIEWS ON THIS POST

105

Posted on:

Wednesday 2nd January 2013
View Replies!

OnClientClick with no postback

Can someone tell me how to stop postback of an asp:linkbuttonNormally I would do this in the page load - btn.Attributes.Add("OnClick", "return false"), however this button is inside a gridview and I would really like to be able to set this in the html of the page.\tI tried OnClick="return false" but that gives an error because it can't find the sub.\tI think I've seen this before, but I can't remember how.\tAny thoughts
VIEWS ON THIS POST

167

Posted on:

Wednesday 2nd January 2013
View Replies!

Create Folder on Server?

Can anyone provide an example of how to create a folder on the server from within an ASP application (When the user sets up a new project, I want to create a folder on my server with a default set of folders based on the project number automatically).I saw some information about the filesystem object and all that, but it seems to be using COM or something. What's the clean easy way in 2.0 :) lol
VIEWS ON THIS POST

119

Posted on:

Wednesday 2nd January 2013
View Replies!

ASP.NET + Outlook 2003 Contact Information

Hi everybody,I am desparate, I can't get this code to work from an ASP.NET webpage.Problem is when I try to retrieve contact information and I get to MyDataRow("Tel.") = MyContact.BusinessTelephoneNumber, My App just hangs. I think it is because normally a dialog box would open up and say that an external program is trying to "connect" to outlook and if I want to allow it.Does anybody know a workaroundThank you in advance,MyOutlook = New Outlook.ApplicationMyNamespace = MyOutlook.GetNamespace("MAPI")Dim MyOutlookProcess() As ProcessMyOutlookProcess = Process.GetProcessesByName("OUTLOOK")If MyOutlookProcess.Length > 0 ThenMyNamespace.Logon(Nothing, Nothing, True, False)ElseMyNamespace.Logon(Nothing, Nothing, True, True)End IfMyContactFolder = MyNamespace.GetFolderFromID(GlobalSettings.SelectedContactFolder)MyContactDataTable = New DataTable("Kontakten")MyContactDataTable.Columns.Add(New DataColumn("Select", System.Type.GetType("System.Boolean")))MyContactDataTable.Columns("Select").owDBNull = FalseMyContactDataTable.Columns.Add(New DataColumn("Objekt-Nr."))MyContactDataTable.Columns.Add(New DataColumn("KundenTyp"))MyContactDataTable.Columns.Add(New DataColumn("Firma"))MyContactDataTable.Columns.Add(New DataColumn("Strasse"))MyContactDataTable.Columns.Add(New DataColumn("PLZ"))MyContactDataTable.Columns.Add(New DataColumn("Ort"))MyContactDataTable.Columns.Add(New DataColumn("Name"))MyContactDataTable.Columns.Add(New DataColumn("Geburtstag"))MyContactDataTable.Columns.Add(New DataColumn("Vorname"))MyContactDataTable.Columns.Add(New DataColumn("Abteilung"))MyContactDataTable.Columns.Add(New DataColumn("Tel."))MyContactDataTable.Columns.Add(New DataColumn("Fax"))MyContactDataTable.Columns.Add(New DataColumn("Mobil"))MyContactDataTable.Columns.Add(New DataColumn("Mail"))MyContactDataTable.Columns.Add(New DataColumn("Internet"))MyContactDataTable.Columns.Add(New DataColumn("Bemerkungen"))MyContactDataTable.Columns.Add(New DataColumn("InDB"))If SelectedInDB = "Nein" ThenSelectedInDB = "N"ElseSelectedInDB = "J"End IfFor Each MyContact In MyContactFolder.ItemsDim ObjectID As String = ""Dim InDB As StringDim KundenTyp As StringDim PropertyNumber As StringTryIf Not IsNothing(MyContact.ItemProperties("ID").Value) ThenObjectID = MyContact.ItemProperties("ID").ValueElseObjectID = i & "T"End IfCatch ex As ExceptionObjectID = i & "T"End TryTryIf Not IsNothing(MyContact.ItemProperties("InDB").Value) ThenInDB = MyContact.ItemProperties("InDB").ValueElseInDB = "N"End IfCatch ex As ExceptionInDB = "N"End TryTryIf Not IsNothing(MyContact.ItemProperties("KundenTyp").Value) ThenKundenTyp = MyContact.ItemProperties("KundenTyp").ValueElseKundenTyp = ""End IfCatch ex As ExceptionKundenTyp = ""End TryIf SelectedKundenTyp = "" Or KundenTyp = SelectedKundenTyp ThenIf InDB = SelectedInDB ThenDim MyDataRow As DataRowMyDataRow = MyContactDataTable.NewRowMyDataRow("Select") = FalseMyDataRow("Objekt-Nr.") = ObjectIDIf KundenTyp.Trim = "" ThenMyDataRow("KundenTyp") = ""ElseMyDataRow("KundenTyp") = DBKundenTyp.GetKundenTypBeschreibung(KundenTyp)End IfMyDataRow("Firma") = MyContact.CompanyNameMyDataRow("Strasse") = MyContact.BusinessAddressStreetMyDataRow("PLZ") = MyContact.BusinessAddressPostalCodeMyDataRow("Ort") = MyContact.BusinessAddressCityMyDataRow("Name") = MyContact.LastNameMyDataRow("Geburtstag") = MyContact.BirthdayMyDataRow("Vorname") = MyContact.FirstNameMyDataRow("Abteilung") = MyContact.DepartmentHere it just hangs and nothing happens anymore --> MyDataRow("Tel.") = MyContact.BusinessTelephoneNumberMyDataRow("Mobil") = MyContact.MobileTelephoneNumberMyDataRow("Fax") = MyContact.BusinessFaxNumberMyDataRow("Mail") = MyContact.Email1AddressMyDataRow("Internet") = MyContact.BusinessHomePageMyDataRow("Bemerkungen") = MyContact.BodyMyDataRow("InDB") = InDBMyContactDataTable.Rows.Add(MyDataRow)End IfEnd Ifi += 1Nextdatagrid1.DataSource = MyContactDataTabledatagrid1.DataBind()Catch ex As ExceptionMyNamespace.Logoff()MyOutlook.Quit()Exit SubFinallyMyNamespace.Logoff()MyOutlook.Quit()datagrid1.Visible = TrueEnd Try /Peace2u
VIEWS ON THIS POST

225

Posted on:

Wednesday 2nd January 2013
View Replies!

Confused over data display

HiI have an xml document read by an xmldatasource.Bound to this is a repeater.I have a button - in the click event I want to add an element to the xml doc and redisplay in the repeater.I have the new element being added OK, but it's hit & miss whether the just added item appears in the repeater.\tSeems to be every other postback, but sometimes every postback.Probably something to do with when/how I'm rebinding.\tI'd appreciate your assistance.CODE\tProtected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load\t\t\t\txmlDSBACSPayment.DataFile = "\\ldnps0001\daar01$\Visual Studio 2005\WebSites\WebSite1\Payments\BACS\" & Date.Today.ToString("yyyyMMdd") & ".xml"\t\t\t\txmlDSBACSPayment.DataBind()\t\t\t\trptPayments.DataBind()\t\tEnd Sub\t\t\t\tProtected Sub btnSavePayment_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnSavePayment.Click\t\t\t\t'add the new payment detail into the xml file & display\t\t\t\tDim myXml As New System.Xml.XmlDocument\t\t\t\tmyXml.Load(xmlDSBACSPayment.DataFile)\t\t\t\tDim path As String = "bacs/payments"\t\t\t\tDim paymentsNode As System.Xml.XmlNode = myXml.SelectSingleNode(path)\t\t\t\tDim elem As System.Xml.XmlElement = myXml.CreateElement("payment")\t\t\t\tDim attr As System.Xml.XmlAttribute = myXml.CreateAttribute("beneficiaryname")\t\t\t\tattr.Value = "benename"\t\t\t\telem.Attributes.Append(attr)\t\t\t\tDim attr2 As System.Xml.XmlAttribute = myXml.CreateAttribute("amount")\t\t\t\tattr2.Value = "0.00"\t\t\t\telem.Attributes.Append(attr2)\t\t\t\tDim attr3 As System.Xml.XmlAttribute = myXml.CreateAttribute("sortcode")\t\t\t\tattr3.Value = "203507"\t\t\t\telem.Attributes.Append(attr3)\t\t\t\tDim attr4 As System.Xml.XmlAttribute = myXml.CreateAttribute("accountnumber")\t\t\t\tattr4.Value = "888888"\t\t\t\telem.Attributes.Append(attr4)\t\t\t\tDim attr5 As System.Xml.XmlAttribute = myXml.CreateAttribute("reference")\t\t\t\tattr5.Value = "the ref"\t\t\t\telem.Attributes.Append(attr5)\t\t\t\tDim attr6 As System.Xml.XmlAttribute = myXml.CreateAttribute("order")\t\t\t\tattr6.Value = "the order"\t\t\t\telem.Attributes.Append(attr6)\t\t\t\tpaymentsNode.AppendChild(elem)\t\t\t\tmyXml.Save(xmlDSBACSPayment.DataFile)\t\t\t\txmlDSBACSPayment.DataFile = xmlDSBACSPayment.DataFile\t\t\t\txmlDSBACSPayment.DataBind()\t\t\t\trptPayments.DataBind()\t\tEnd Sub
VIEWS ON THIS POST

130

Posted on:

Wednesday 2nd January 2013
View Replies!

Session State and Webservices

In my global asax I have:\t\t\t\tprotected void Global_AcquireRequestState(Object sender, EventArgs e)\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t\t// set the security principal to our BusinessPrincipal\t\t\t\t\t\tif(Session["CSLA-Principal"] != null)\t\t\t\t\t\t{\t\t\t\t\t\t\t\tThread.CurrentPrincipal = (IPrincipal)Session["CSLA-Principal"];\t\t\t\t\t\t\t\tHttpContext.Current.User = Thread.CurrentPrincipal;\t\t\t\t\t\t}\t\t\t\t}If I navigate to a webservice, I get the error:Session state is not available in this context. I need the session code in my global.asax file for the rest of my site, but it seems to be causing issues with webservicesWhat am I doing wrong
VIEWS ON THIS POST

150

Posted on:

Wednesday 2nd January 2013
View Replies!

Replace string in Response

Can anyone tell me how I can replace a string in the Response And in which event to do this.I have a 3party tool that injects some javascript function into the page. I want to filter this function
VIEWS ON THIS POST

105

Posted on:

Wednesday 2nd January 2013
View Replies!

Compare effeciency

i have a table like thisUserId\t\tScore1\t\t\t\t\t\t152\t\t\t\t\t\t301\t\t\t\t\t\t452\t\t\t\t\t\t50This is the basic SQL i run to get the score per user:select UserId,count(Score) from Table1 group by UserIdNow i want the Total Score(=15+30+45+50) also in the resultset (AS i need to calculate the %).i.e. i am looking for a display like this:UserId\t\tScore Total1\t\t\t\t\t\t15\t\t1402\t\t\t\t\t\t30\t\t1401\t\t\t\t\t\t45\t\t1402\t\t\t\t\t\t50\t\t140I can do this in either SQL server or in .NETIf i do this i SQL i would write something like this:select * from (select UserId,count(Score) from Table1 group by UserId) Table1Left Join(select count(Score) from Table1 group by UserId) Table2on 1=1How effecient is thisIf i have to use .NET then i have to use DataSets (as calculations with datareaders is difficult after the DataReader s bound)So the comparison i am making is calculating in .NET(Using a DataSet) Vs writing the query in SQL server... Known is handfull, Unknown is worldfull
VIEWS ON THIS POST

216

Posted on:

Wednesday 2nd January 2013
View Replies!

Databind Problem w/ Label Object

I am trying to get a lblName binded to a DataSet11. Specifically a Field on a Table named Written Name. I realized that there is a way to code this but I was trying to get it to work with Visual Studio .Net (Connection,Adapter,and DataSet). I have a SQLAdapter & DataSet Object but for some reason when I select the Databind Property on the label to Bind it, it allows me to find the Table and Column but won't place it in the property for use. I know this sounds strange so I can clarify if need be..if anyone has any suggestions I would appreciate it. Someone told me that I must code some of it out prior to trying this. However, this is not a diffilcult task and I think Visual Studio does all this for you...
VIEWS ON THIS POST

105

Posted on:

Wednesday 2nd January 2013
View Replies!

Another Crystal Question

Sorry for so many questions regarding crystal but here goes..How to do you connect a report to an SP or a dataset or reader any help would be appreciated
VIEWS ON THIS POST

110

Posted on:

Wednesday 2nd January 2013
View Replies!

Refer parent function in custom control???

i want to build a custom control that has a overridable function. This function can be overridden by the implementing page.e.g.:.ascx file has this functionpublic overridable FunctionName() as booleanend functionin .aspx i need to be able to override this function. like so:overrides FunctionName() as booleanresponse.write("Yeah!!!")end functionbut since the aspx file inhertis from page it is unable to override the custom control function.Can this be done\t I am open to other suggestions for implementing the same functionality... Known is handfull, Unknown is worldfull
VIEWS ON THIS POST

221

Posted on:

Wednesday 2nd January 2013
View Replies!

Custom validation only works on localhost

Hi .\tI got a custom validator that only seems to fire if i use my localhost.\tThe minute i put it on the web server the validation stops fireing.Any ideas
VIEWS ON THIS POST

103

Posted on:

Wednesday 2nd January 2013
View Replies!

whats wrong?? dataset expected type... (from a newby)

. i am trying to learn asp.net!! but stuck here. gives me type expected" error for "dataset". couldnt understand... help..Public Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs)\t\t\t\t\t\t\t\tDim ds As dataset = New dataset\t\t\t\tDim tablo As New DataTable("customer")\t\t\t\ttablo.Columns.Add("name", System.Type.GetType("system.string"))\t\t\t\ttablo.Columns.Add("surname", System.Type.GetType("system.string"))\t\t\t\ttablo.Columns.Add("occup", System.Type.GetType("system.string"))\t\t\t\ttablo.Columns.Add("old", System.Type.GetType("system.int32"))\t\t\t\t'ds.tables.add(tablo)\t\t\t\tDim a As DataRow = tablo.NewRow\t\t\t\ta("name") = "abc"\t\t\t\ta("surname") = "cde"\t\t\t\ta("occup") = "fgi"\t\t\t\ta("old") = "29"\t\t\t\t'tablo.Rows.Add(a)\t\t\t\t\t\tEnd Sub
VIEWS ON THIS POST

125

Posted on:

Wednesday 2nd January 2013
View Replies!

Application Hangs Up on Pocket PC Only

I have an ASP .NET web application that is used to scan parts for orders. I have tested with both a Windows XP Professional workstation using IE and a Pocket PC using Pocket IE. Basically, the process is to enter 3 text fields, either by scanning or typing, then press the "Add" button. The added parts are stored in a cookie on the client and then displayed in a DataGrid on the same page. These accumulate until another button is clicked. After "Add" is clicked for the 68th part, Pocket IE just sits there with the Windows logo moving; it will not continue. I have run the app in debug, and nothing appears to happen on the server side once "Add" is clicked. The Page Init, Load, and PreRender are not executed, and the button click procedure is not executed. I have checked this with Debug and Trace statements, as well as setting breakpoints in the code. I have also tried doing a "Break " at the point the app hangs, and I get the message "There is no source code available for the current location."\tThere is no problem if the exact same test data is used on a Windows XP machine; it can add more than 68 parts.\tThe Pocket PCs have 64MB of memory, and are connecting to the network via a wireless connection. Any ideas of what I can check next to find the problem Is there a limitation on the amount of data a Pocket PC can post back to the server Or a cookie size limitation on Pocket PC
VIEWS ON THIS POST

158

Posted on:

Wednesday 2nd January 2013
View Replies!

Single record update - need advice

I'm learning asp.net at the moment to develop my new websites. Iv'e used traditional asp for a number of years. I did a course on .net a few weeks ago and covered things such as datagrids, datasets etc. Iv'e managed to create datagrids that edit/update/delete records, and have forms to add a new record to an table in MS SQL in .net. The one bit I'm missing is where I want to update a single record where its number of fields is to big to fit in a datagrid row and therefore needs displaying in a single form.ie I have a record withTitle of workshopDescriptionStart dateEnd dateLinkTutorCommentsetc...What I did in asp was pass the ID of the record to an asp form read the database with a 'SELECT * FROM table WHERE ID=" + Request.QueruString("ID") which poulated the fields with the existing data in this record, the user then alters what they want and the data is written back to the table (theres only one administrator doing this so I don't have to worry about locking records etc). Where I get stuck in .net is how do I populate the fields Datasets seem too much for what is essentially reading just a single record, as does a datagrid. Really I want a form with a set of text fields and submit button, and someway of binding a single record field value to each of these fieldsFrom looking on the web it seems using a datatable might be the solution, but we didn't cover this is the course and its unclear to me the best way to get a single record into a datatable and then 'bind' it to each of the controls.The lack of data on the web suggests to me that I might not be understanding the .net paradigm rather than implementing. What is the best way of dealing with updating single records where the number of fields/size of fields is too big to display in a datagrid.The database I'm using is MS SQL Serve
VIEWS ON THIS POST

214

Posted on:

Wednesday 2nd January 2013
View Replies!

How many layers are best practice?

I occasionaly, while being in a deep "flow" of programming, run into these mind-design-problems, which i seem to forget but today i wrote one down. Suppose you have an item class, an item collection class, a dataclass (which fills the collection class with items stored in a database or flat file) and an e.g. "weblog" classto fill a collection you could instantiate the collection class in the weblog class as well as instantiate the dataclass in the weblogclass and fill it in the weblog class. In this way the collection class does not have to have a method called "fillme", which could be called to fill the collection class.On the other hand if the collection class would have a method called fillme it would make the weblog class much more simple since you would simply have to call something like weblogitemcollection.fillme and it would be filled... nog direct access needed to a dataclass whatsoever but... the single classes would be not so reusable since this specific dataclass in the collection class would always be needed.So you would have always have a item.cs, collection.cs, data.cs and weblogs.cs but the way you would call each other\tand which methods to include in each of these classes, in other words, the relations they have would differ.Another way would be to include an extra class, something like collectiondata.cs which would enable collection.cs to call something generic in collectiondata.cs to call data.cs.Which is the best way according to best practices -- http://leau.net
VIEWS ON THIS POST

361

Posted on:

Wednesday 2nd January 2013
View Replies!

asp / javascript checkbox enable/disable issue

I have a 4 sets of checkboxes and text boxes on an aspx page.\tThe checkboxes are disabled by default but when the text box next to it has text entered into it, the checkbox is supposed to enable.The problem is, the value is changed when I step through it in the debugger but the page is not. (checkboxes stay disabled on the page, but the value of checkbox.disabled = false)If i REVERSE this, making the checkboxes enabled by default and then try to disable them when text is entered, it works fine.Any suggestionsmy code looks like:CODE//elemArray[6] has checkbox.ClientID valuedocument.forms[0][elemArray[6]].disabled = false
VIEWS ON THIS POST

124

Posted on:

Wednesday 2nd January 2013
View Replies!

Where is my .xsd file?

I am reading one of my books on ADO.NET and it says that XML is automatically generated for me.\tIs this always the case\tI am connecting to SQL Server, so my question is... Is XML being used for the transfer\tI really don't know that much about ADO.NET, but I am going to attend a class on it in Feb.\tand help would be appreciated.
VIEWS ON THIS POST

145

Posted on:

Wednesday 2nd January 2013
View Replies!

Linkbutton color

How do I change the color of a LinkButton text.I am creating the linkbutton in code at run time.I only want to change the color of a particular button not the whole pag
VIEWS ON THIS POST

116

Posted on:

Wednesday 2nd January 2013
View Replies!

Stream was not readable from mscorelib with BinaryReader with PDF

I am getting error when I try to open PDF documdent using binary read. Line # 106 where error is occuring is binaryReader = New BinaryReader(HttpWResp.GetResponseStream())Error Source mscorlib : Stream was not readable. System.ArgumentException: Stream was not readable. at System.IO.BinaryReader..ctor(Stream input, Encoding encoding) at System.IO.BinaryReader..ctor(Stream input) at FileNetSearch.FileNetSearch.GetReport.ReturnPictureBinary(String sUrl, String& sContentType, String& sErrTxt) in c:\inetpub\wwwroot\SearchDoc\GetPDF.aspx.vb:line 106 Does anyone has any idea what is going worng in this.
VIEWS ON THIS POST

129

Posted on:

Wednesday 2nd January 2013
View Replies!

Do you know the tool to create image for image button?

I knew that most graphic software can do it. What I am looking for is a tool can create image for button, I can design what type, style, color and can type text on it easier. Anyone can recommend it
VIEWS ON THIS POST

131

Posted on:

Wednesday 2nd January 2013
View Replies!

binding dropdown within datagrid

I have a datagrid. The datagrid has a footer, and one of the columns in this footer is a dropdown list.\t\t...\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tI am trying to bind this dropdown list to a column in the databaseadd_attribute.DataSource = ds.Tables[0];add_attribute.DataTextField = ds.Tables[0].Columns["ss_attribute_name_c"].ColumnName.ToString();add_attribute.DataValueField = ds.Tables[0].Columns["o_id"].ColumnName.ToString();add_attribute.DataBind();BUT I get the error that the add_attribute could not be found. I guess it is because it is a part of the datagrid.How can I bind the dropdown within the datagrid with the column in the databaseAny suggestionsThank you,Marika
VIEWS ON THIS POST

107

Posted on:

Wednesday 2nd January 2013
View Replies!

Uploading all files in a particular directory

Is there a way to upload all files from a particular directoryI need the user to upload pictures so, instead of one-by-one uploading (using the file control), I would like the user to be able to point to a particular directory and click "upload" then, the asp.net app will loop for each jpg file and upload it.Is that even possible Let me put it this way:While StressLevel Is High\tProductivity -= 1\tMarriage = NothingEnd While
VIEWS ON THIS POST

87

Posted on:

Wednesday 2nd January 2013
View Replies!

data reader question

Can somebody please tell me if I am going about this task the right way I have a recordset that I want to read and then perform a test and an update on each record in the recordset.\tShould I use a datareader to read the data and then a foreach loop to do my test and update And if so, what would the syntax of my foreach loop bestring strGetCartDetails = "SELECT S.PRODUCTID AS 'Product ID', ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "'5.00' AS 'Unit Price (GBP)', S.SIPDOMAIN AS 'SIP Domain', ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "S.QUANTITY as 'Quantity', C.SIPACCOUNT AS 'SIP Account', N.STARTRANGE, N.ENDRANGE ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "FROM NUMBER_RANGES N INNER JOIN ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "SHOPPING_CART S ON ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "S.PRODUCTID = N.RECORDNUM ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "INNER JOIN SHOPPING_CART_SIP C ON ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "C.SCRECORDID = S.SCRECORDID ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "WHERE S.CARTID = '" + strCartID + "' ";\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrGetCartDetails += "ORDER BY N.RECORDNUM";\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tSqlConnection objConnectionGetCartDetails = new SqlConnection(ConfigurationSettings.AppSettings["strConnectTest"]);\t\t\t\t\t\t\t\t\t\t\t\t\t\tSqlDataReader objDataReaderGetCartDetails = null;\t\t\t\t\t\t\t\t\t\t\t\t\t\tSqlCommand objCommandGetCartDetails = new SqlCommand(strGetCartDetails, objConnectionGetCartDetails); \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tobjConnectionGetCartDetails.Open();\t\t\t\t\t\t\t\t\t\t\t\t\t\tobjDataReaderGetCartDetails = objCommandGetCartDetails.ExecuteReader();\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (objDataReaderGetCartDetails.Read() == true)\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t //do foreach\t\t\t\t\t\t\t\t\t\t\t\t\t\t
VIEWS ON THIS POST

98

Posted on:

Wednesday 2nd January 2013
View Replies!

sql server

Hi to all,I have some basic knowledge of sql server and asp.net. Now I would like to write a program that interacts between both. Can someone give me please some guidelines, how I should do this Should this special code be added to the asp.net code or sql server code Actually, I would like to read some input values through an asp.net page and initialize some fields of sql table. Furthermore, if someone knows useful links on the matter, please tell me
VIEWS ON THIS POST

107

Posted on:

Wednesday 2nd January 2013
View Replies!

redirect to new link

hi, below is the code, after login successful, i want to redirect the user to a new link. The code redirect back to http://localhost/test/mail.anyone.com/UserEmail. How can I redirect to http://mail.anyone.com/UserEmail
VIEWS ON THIS POST

103

Posted on:

Wednesday 2nd January 2013
View Replies!

Problem turning of validator client side

all,I am having trouble with a required validator.\tI have several validators on a page that are enabled or disabled depending on what is selected in a drop down box.To disable them client side, I use ValidatorEnable(ID, true/false).\tThis works for all the validators I disable on the form.However, on the server-side when I perform a page.isValid it fails because one of this disabled validators is now considered not valid.I have having trouble figuring out why a disable validator returns isvalid = true client side and isvalid = false when it gets to the server side.\tI am not sure if posting any of my code will help or not
VIEWS ON THIS POST

135

Posted on:

Wednesday 2nd January 2013
View Replies!

how to color a individual search word?

I created a search app to search address and display in datagrid. I used dataset to bind to a datagrid. SQL statement like: "select [address] from TABLE_ORDER where [address] like '% " & strKeyword & "'. User can input "main st" or "Franklin"... to search address. I want to color the the "main st" or "Franklin"... How to code it
VIEWS ON THIS POST

133

Posted on:

Wednesday 2nd January 2013
View Replies!