Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. tcstom

    Problem dynamically rendering DropDownList in custom control...

    Sorry, it was too long ago now. I really don't remember what I was working on...
  2. tcstom

    Table not appearing in list when creating diagram

    Sorry SQLDenis, I've looked again and they're there. Either it was my mistake or something hadn't refreshed. Sorry for wasting your time.
  3. tcstom

    Table not appearing in list when creating diagram

    On SQL Server 2000 I've created a few tables directly using the SQL CREATE TABLE syntax but the tables I've created are not appearing in my list of available table names when creating a diagram. What else must I do to make these tables appear...?
  4. tcstom

    Force login after browser closed

    Better than nothing (which is the alternative) though!
  5. tcstom

    Storing cookies in ASP.NET - works in Firefox/Safari but not IE

    Who would have thought it! It turns out that the solution is to supply a 'compact privacy policy' with your page. So, for every page that will be writing a cookie from an iFrame, include the following line of code: HttpContext.Current.Response.AddHeader("p3p", "CP=\""IDC DSP COR ADM DEVi TAIi...
  6. tcstom

    Force login after browser closed

    Good point. How about using onbeforeunload instead? I think Firefox recognises that one. My code above may need to be changed though because onbeforeunload works differently (from memory).
  7. tcstom

    Storing cookies in ASP.NET - works in Firefox/Safari but not IE

    I should have mentioned that the page writing the cookie is in an iframe and I've now discovered that IE by default blocks such cookies as untrustworthy. Why can't Microsoft just follow the rules? If anyone knows a work-around I'd be enormously grateful. The iframe here is necessary.
  8. tcstom

    asp.net image caching and wcf secutity issue

    Could you find a different method of passing the encrypted key to getimage.aspx, like maybe storing it in the session when the page containing the image loads...?
  9. tcstom

    dropdownlist not showing value stored

    In VB doesn't an apostrophe (') denote a comment? And your lines that try to set the SelectedIndex both begin with apostrophes...
  10. tcstom

    Storing cookies in ASP.NET - works in Firefox/Safari but not IE

    I'm using the following code to write a cookie... HttpCookie objCookie = new HttpCookie("TCS_DATA_REQUEST"); objCookie.Expires = DateTime.Now.AddYears(1); objCookie.Values.Add("TCS_DATA_PROVIDED", "yes"); Response.Cookies.Add(objCookie); ...and then as part of a subsequent page load I'm using...
  11. tcstom

    Force login after browser closed

    Or you could use Javascript to make an AJAX call to a page that ends the session in response to the window.onunload event. I've used the following code which allows you to determine if the user has closed the browser... window.onunload = function() { // The following test determines if the...
  12. tcstom

    Custom control question

    (Sorry, it's called CreateChildControls)
  13. tcstom

    Custom control question

    Thanks tperri. However, I'm looking to create a custom control that contains numerous other controls as well as the button. I had tried adding them programmatically in the Render method (and they were not persisting across postbacks) but have since learnt about the AddChildControls method which...
  14. tcstom

    Custom control question

    I'm trying to create a custom control library for the first time and I'm a bit stuck. I need a custom control that contains a button which, when clicked, fires a custom event. If it were a user control this would be easy because I could write a Button control into the ascx file and set its event...
  15. tcstom

    Problem dynamically rendering DropDownList in custom control...

    Sorry, my mistake, the problem was with how I was managing the ViewState. It's OK...!
  16. tcstom

    Comparing date from SQL Serv with System.Date.Now

    if ((DateTime)this.Fields["dtCertExpire"].Value > System.DateTime.Now)...
  17. tcstom

    Problem dynamically rendering DropDownList in custom control...

    Part of my Render method in a custom control contains the following code... DropDownListOfStaff.Items.Add(new ListItem("test", "test")); DropDownListOfStaff.RenderControl(writer); ...where DropDownListOfStaff is a DropDownList instantiated programmatically. The rendered HTML has this SELECT...
  18. tcstom

    datagrid - confirm entry before posting

    Give all these LinkButtons the same CSS class. Then using Javascript you can loop through all your anchor tags as part of a window.onload event handler. For each anchor with this class you can then add your onclick event handlers. So, if all these LinkButtons has the class 'do_confirm' just add...
  19. tcstom

    Column number from Itemdatabound help

    How about this? bool isOddCell = false; for (int i = 0; i < e.Item.Cells.Count; i++) { isOddCell = !isOddCell; if (e.Item.Cells[i].Text == "Empty") { if (isOddCell) e.Item.CssClass = "odd"; else e.Item.CssClass = "even"; } }
  20. tcstom

    Preventing double click

    As part of the window.onload function... var processing = false; document.getElementById('id_of_my_link').onclick = function() { if (processing) return false; else { processing = true; // Do the work and set processing back to false at the end } }

Part and Inventory Search

Back
Top