Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
J

jboyd111

@jboyd111
About
Posts
24
Topics
13
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • "Microsoft JScript runtime error: Object expected" using Telerik MVC controls
    J jboyd111

    I'm getting the "Microsoft JScript runtime error: Object expected" error using Telerik for MVC. These are the lines causing the issue:

    @Html.Telerik().ScriptRegistrar().OnDocumentReady(
    @<text>
    /* attach event handler to "check all" checkbox */
    $('#checkAllMembers').click(function checkAll()
    {
    $("#ResultsGrid tbody input:checkbox").attr("checked", this.checked);
    });
    </text>)

    The thing is, the checkAll function actually does work! I have the following line at the top of my view:

    Layout = "~/Views/Shared/SiteLayout.cshtml";

    <link href="@Url.Content("~/Content/Site.css")" rel="Stylesheet" type="text/css" />
    <script src="@Url.Content("~/Scripts/jquery-1.5.1.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery-1.5.1-vsdoc.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/MicrosoftAjax.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/MicrosoftMvcAjax.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/MicrosoftMvcValidation.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery-ui-1.8.11.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery-ui-1.8.11.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.unobtrusive-ajax.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.validate-vsdoc.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/modernizr-1.7.min.js")" type="text/javascript"></script>
    @(Html.Telerik().StyleSheetRegistrar().DefaultGroup(group =>

    ASP.NET javascript help html css asp-net

  • Using Telerik MVC Extensions to select all checkboxes in a grid
    J jboyd111

    Hello, I'm trying to use the Telerik grid control. I've followed the demo listed here. I've implemented the code in a very similar fashion with a few changes due to some "quirks". The ID of my checkbox header column is "checkAllMovies" I've spent most of the day getting it working. I'm now stuck on the part where I want it to select all check boxes. There's a bit of code at the bottom of my "view" file within my form:

    @Html.Telerik().ScriptRegistrar().OnDocumentReady(
    @<text>
    /* attach event handler to "check all" checkbox */
    $('#checkAllMovies').click(function checkAll()
    {
    $("#Grid tbody input:checkbox").attr("checked", this.checked);
    });
    </text>);

    This doesn't seem to work/do anything. I'm new to the Telerik MVC controls (Open source). Thanks in advance for any assistance. - jboyd

    ASP.NET asp-net html css com architecture

  • Join and Update statement using junction table and sql
    J jboyd111

    OK, thank you, I'll think along the lines of DELETE and INSERT. The next step is to have this work with an SqlDataSource1_Updating method with my Gridview control in C#. Thanks to all for your help.

    Database csharp asp-net database sql-server help

  • Join and Update statement using junction table and sql
    J jboyd111

    Thanks for your help. I apologize I hadn't been able to properly characterize my problem. In short: I want to update a junction table (RoleId and UserId) when I only know the UserName and RoleName. I'll play around with variations of what you provided and search a bit further online. I'll post whatever resolution(s) I come up with.

    Database csharp asp-net database sql-server help

  • Join and Update statement using junction table and sql
    J jboyd111

    Your last point is what I'd like to find an answer for: I want to UPDATE the RoleId for an EXISTING RoleId,UserId combo. In short, I want to update the junction table.

    Database csharp asp-net database sql-server help

  • Join and Update statement using junction table and sql
    J jboyd111

    Hi, I've searched and haven't found a relevant answer to this 'simple' problem. I have 3 tables, one of which is a junction table between the other two: Users ----- UserId UserName Roles ----- RoleId RoleName UserRoles --------- UserRoleId UserId RoleId There are FK relationships between UserRoles and the other 2 tables. Problem statement: What I want to do is update the user's RoleId in the UserRoles table if I only have the person's RoleName and UserName. Here's what I'm starting with code-wise (MSSQL): update a set a.RoleId = ?? Set to what? FROM UserRoles a inner join Users b on a.UserId = b.UserId inner join Roles c on a.RoleId=c.RoleId where c.RoleName= 'Administrator' AND b.UserName='someuser' Further information: I'm trying to do this within an update method call within an ASP.NET GridView control. This information may be a bit more than what's needed but I thought I would mention it just in case it may offer a different solution. Thanks for any assistance in advance. --- Stan

    Database csharp asp-net database sql-server help

  • Visual Studio 2010 Web performance test password encryption question
    J jboyd111

    Hello, I've created a web performance test that logs me in to an internal site. I want to be able to hide the password in the code so I can check it into VSS. I see that creating CodedUI tests seem to encrypt the passwords (i.e. you see what looks to be a hash string instead). Is there a way to more easily do that with web performance tests? Thanks in advance for any assistancee. ------ jboyd

    C# question csharp visual-studio security cryptography

  • Extract data for a form using web performance test tool visual studio
    J jboyd111

    Hello, we have an internal web app where, we create an "ticket" then save it (it generates a new ticket ID). What I want to be able to do is capture that dynamic id and use it as input to a search box on a separate page. I need to do this so I can search for that ID and open the ticket in read-only (view) mode in order to validate the values of a couple of fields. Extracting the ID from the creation page and hoping that gets inputted into the text box on the search page doesn't work because when I bring up the search page while recording, the search textbox is empty. I have to manually put in a value to search for (i.e. ticket id). I know I could create a coded test from this and pass the dynamic values that way. Any help/suggestions would be greatly appreciated. -------------------------------------------------------------------------------- jboyd

    ASP.NET csharp visual-studio performance help

  • Can't see coded web performance test in VS 2010
    J jboyd111

    Amazing at times, annoying at others! :)

    ASP.NET help visual-studio performance

  • Can't see coded web performance test in VS 2010
    J jboyd111

    FINALLY! OK, here's what I did to resolve the issue: 1) From the Build menu I chose to Build my test project. Building/Rebuilding the solution did NOT do the trick. I had to explicitly choose my test project name from the Build menu. 2) Then I selected Test ->Windows -> Test View. This showed my web performance AND coded tests. Hope this helps others who have this issue!

    ASP.NET help visual-studio performance

  • Can't see coded web performance test in VS 2010
    J jboyd111

    I've been baning my head against the wall for the better part of a day on this issue. I cannot run my coded web performance test. I'm using VS 2010 Ultimate. I can do the steps below with no problem using other solutions (even by creating a new solution!) but not with one particular solution. Here's what I've done: 1) Added a web performance test project to my solution 2) recorded a few mouse clicks in the open browser window 3) ran (repeatedly) the resultant web performance test. Works great! 4) Clicked the Generate Code button in the web test viewer window, which does create a .cs test 5) Chose Test-> Run -> All Tests in Solution. Only the original web performance test shows up in the Test Results window I want/need the .cs test to compile because I need the .dll for use with a test plan from within Test Manager. ANY help would be GREATLY appreiciated. Thank you. -------------------------------------------------------------------------------- jboyd

    ASP.NET help visual-studio performance

  • Word c# interop bookmark issue(s)
    J jboyd111

    I have a winform app that writes a word document template to a database. I'd like to read this back in and insert text at cartain points in the document. I've been reading the web and it looks like using bookmarks is the way to go. I'm stuck on setting bookmarks, however. My code is below:

    object oNull = System.Reflection.Missing.Value;

            Word.Range start = para.Range;
            object oRng = start;
    
            string newText = "Bookmark1";
            Word\_doc.Bookmarks.Add(newText, ref oRng);
    

    when I run it the traceback shows: "...Bad bookmark name." This is at the line: "Word_doc.Bookmarks.Add(newText, ref oRng);" 2 questions then are: 1) How do I properly set a bookmark in a word doc using interop (automation)? 2) Is there another/better way to be able to insert a table at a certing location in a word doc? Thanks in advance. Jboyd

    .NET (Core and Framework) help question csharp database com

  • Anonymous usser URL access testing issues
    J jboyd111

    Here's a brief update after poking around a bit. I notice I get different behavior when I set "NetworkCredential" to my valid username and password then when I use "CredentialCache.DefaultCredentials". When I use "NetworkCredential", I can now access the URLs that allow "anonymous" access. But I now geet "401" errors with all other URLs. In short: a. Using "CredentialCache.DefaultCredentials" gives me access to all URLs b. Using "NetworkCredential" (with correct username and password) gives me access to URLs allowing "anonymous" access. Question: why do these behave differntly?

    ASP.NET question com sysadmin windows-admin testing

  • Anonymous usser URL access testing issues
    J jboyd111

    It does allow it if you come in from a web browser like internet explorer. This is within a company network so no one from outside can access the site, of course. The issue is you can log out of or into this particular internal site. When you log out of it you can still access this one page. When I try this using ASP.NET (HttpWebRequest) I get the error. Perhaps someone can answer this question: By setting my own "NetworkCredential" am I being looked at like I'm trying to access the internal page as though I'm an external user?

    ASP.NET question com sysadmin windows-admin testing

  • Anonymous usser URL access testing issues
    J jboyd111

    I've written a simple web app to test the URLs of our various internal applications to ensure none would allow anonymous login access. I thought all was working fine until another developer mentioned that one of the URLs should be accessible to anonymous users. We use Active directory logins/passwords and membership in order to provide/restrict access to certain pages and applications. When set to default credentials, I get no errors. When I set my network credentials to some made-up user, I get 401 errors, as expected for all URLs. For the URL in question that's accessible to internal anonymous (i.e. not logged-into-this-particular-app) users, I get the "401 access denied" message as well. Here are the main parts of the code: NetworkCredential networkCredential = new NetworkCredential("stan", "abc123"); HttpWebRequest request = (HttpWebRequest)WebRequest.Create("http://www.SomeTestURLHere.com/default.aspx"); CookieContainer cookieContainer = new CookieContainer(); request.CookieContainer = cookieContainer; request.Credentials = networkCredential; using (HttpWebResponse response = (HttpWebResponse)request.GetResponse()) using (Stream dataStream = response.GetResponseStream()) using (StreamReader reader = new StreamReader(dataStream)) { // do work } This is all contained within a try-catch-finally block. With default credentials, I fall through into the "do work" section of the code. With the network credentials I set above, I get the "401" exception, which I would NOT expect for this particular URL since it's supposed to allow anonymous user access. So my question is: why am I getting the 401 message for this page? Thanks in advance for any assistance you can provide.

    ---- Jboyd

    ASP.NET question com sysadmin windows-admin testing

  • How to properly show text for URL link using RichTextBox to output into RTF format?
    J jboyd111

    All, I apologize if this has been answered somewhere in the forum already. I've searched for a couple of hours here and the general web and haven't found a suitable answer. I simply want to output an RTF file that contains hyperlinks (URL) but shows ONLY the text for that link, not both the text and the full URL. Here's brief code snippet that does NOT work as expected: richTextBox1.LoadFile(inputFile, RichTextBoxStreamType.RichText); richTextBox1.SaveFile(outputFile, RichTextBoxStreamType.RichText); This snippet simply reads in an RTF file into a RichTextBox control and saves it back out (This is not what I'm actually trying to do in the long run, I just wanted to isolate the issue for clarity). When I open the files in MS Word: The original file (inputFile) has the text: "Bug# 137". This text is a hyperlink and all you see is the text and you could click it and go to the corresponding web page. The "copied" version of the file contains the text: "Bug# 135 ". This text is blue, and is underlined. Yet there are 2 things wrong with it: 1) It lists the entire URL, not just the text ("Bug# 135") 2) It is not an actual link, just blue, underlined text. I'm using VS 2010. I have explicitly set "DetectURLs" boolean property, though I believe it's set to "true" by default. Any assistance with this "gnawing" issue would be greatly appreciated.

    C# help visual-studio tutorial question announcement

  • LoginStatus not working within master page
    J jboyd111

    I have a user control on my site (in directory UserControls/UserInfo. When I drop the control onto a page created from my master page template, it does nothing (i.e. you click on the "login" link and nothing happens). I even added an explicit link to a Login.aspx url on the LoginStatus line, which will work. However, the LogOut link does not work. I've found I can drop this user control onto any new, blank (i.e. not derived from MasterPage.master) and all works as expected. Also, when I run in debug mode, I get the following error when I click on the Login link: "Microsoft JScript runtime error: Object doesn't support this property or method" The method highlighted is: "theForm.submit();" This call is in the javascript function created to do the postback: function __doPostBack(eventTarget, eventArgument) { if (!theForm.onsubmit || (theForm.onsubmit() != false)) { theForm.__EVENTTARGET.value = eventTarget; theForm.__EVENTARGUMENT.value = eventArgument; theForm.submit(); } } The javascript issues I just listed may be a red herring. I've included the user control code below. Any assistance on why this doesn't work within master pages would be helpful and greatly appreciated. <%@ Control Language="C#" AutoEventWireup="true" CodeFile="UserInfo.ascx.cs" Inherits="UserControls_UserInfo" %>
    ReelPushMowers
    Catalog Admin

    Welcome!

    You are not logged in.

    ASP.NET csharp javascript debugging help

  • Datalist won't display
    J jboyd111

    I apologize, I knew there was something I left out. This is what I had in the code-behind: protected void Page_Load(object sender, EventArgs e) { DataList1.DataBind(); } So, I have a "Default3.aspx" file with the DataList1 control, and a "Default3.aspx.cs" file with the DataBind() call.

    ASP.NET visual-studio sysadmin windows-admin workspace

  • Datalist won't display
    J jboyd111

    Hello, I've been working on an e-commerce site for a couple of weeks. I'm at a point where I want to use a datalist to display a subset of my catalog. Well, nothing in the datalist displays when I bring up the page in IE with either IIS 7 or VS built-in iis server. I've isolated a simple piece of code that illustrates my dilemna within a defalut.aspx file: <form id="form1" runat="server"> <div> <asp:DataList ID="DataList1" runat="server"> <ItemTemplate> Hello! </ItemTemplate> </asp:DataList> </div> </form> This page should show: "Hello", yet the page is blank. More configuration details: - running Windows 7 - VS 2008 - IIS 7 Any assistance or suggestions to point me in the right direction would be greatly appreciated. Thanks in advance.

    ASP.NET visual-studio sysadmin windows-admin workspace

  • Dreamweaver, Visual Studio, c# asp.net web site development tools
    J jboyd111

    Hello, I searched and didn't find a good answer to these specific questions so I thought I'd post them here: - What are some suggestions for the best ways people have used for site design for sites containing asp.net and c#? - I'm getting more into asp.net using VS 2008 but have used Dreamweaver MX for over 5 years. I'd like to continue to use dreamweaver but also use VS for code development. Is that possible? - Do most developers just stick with VS for full site design and deployment? Thanks in advance for your responses and patience with my foolish newbie questions. ----------- Jeff

    ASP.NET csharp visual-studio asp-net design sysadmin
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups