|
Visual inheritance is not supported in web forms. In web forms, create master pages or user controls and include them in the pages.
|
|
|
|
|
hi All
My requirement is when the user copy some html content and past in the editor it should copy the image as well as in the editor.
i tried using tiny editor and other editor but image is not coping.
please guide me with this..
Thanks in advance
Ramkumar
|
|
|
|
|
ramkumarishere wrote: i tried using tiny editor and other editor but image is not coping.
Then you should asked the question to appropriate forum from where you are your using your Editor.
It is quite difficult to tell in this way !
|
|
|
|
|
ramkumarishere wrote: My requirement is when the user copy some html content and past in the editor it should copy the image as well as in the editor.
You can't copy the image. HTML content will have link to image and image will not be copied. All you can do is to find the image URL from the HTML content, download that image from the URL and update the HTML content with valid path to the downloaded image.
Take a look at the methods offered by WebClient class.
|
|
|
|
|
Hi I want to derive aspx page from another aspx page i.e inheritance of aspx page.
I want to inherit one aspx page i.e basic.aspx and its conrol in another aspx page like city master. basic page contain label (serial no.,Id, name), Textbox(serial no.,Id, name)and Bttons (btnadd ,btndelete,btnsave) . this conrol I want to inherit in citymaster.aspx.
modified on Wednesday, October 7, 2009 2:18 AM
|
|
|
|
|
Create a Class inside App_Code like:
public abstract class MyWebPage : System.Web.UI.Page
{
}
Now inherit this call for all your pages where you need the common functionality.
public partial class WebPages_MyTestPAge : MyWebPage
{
}
|
|
|
|
|
I have created one page(aspx) in that page there is textbox,label,button.,i want that control(textbox,..,..)on another page(like inheritd from one page(aspx) to another page(aspx))
|
|
|
|
|
I am facing a peculiar problem in Gridview. Details I mentioned here.
I found out that the issue is because if I set the below code in RowDataBound event.
e.Row.Cells[0].Visible = false;
When I commented this, paging is coming properly. Now the issue is that, first column is visible which is an ID column, which shouldn't show to the user. I couldn't understand how this will affect the paging of Gridview.
Anybody please suggest any way to hide the column without affecting the paging?
Thanks
Success is the good fortune that comes from aspiration, desperation, perspiration and inspiration.
|
|
|
|
|
What if you create a way of storing the value inside each row without it having a column dedicated to it ? What if it's not column 0 you hide, might it work OK then ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
That will work. But how will I store the Id value without a column in a row? The datatable returns 5 columns out of which 1 is Id column.
Is it possible to store the value inside each row without a dedicated column?
Success is the good fortune that comes from aspiration, desperation, perspiration and inspiration.
|
|
|
|
|
Instead of using standard columns, write your own column definitions. You could then have a control in one column that renders the data you want to see, and has an id which contains the id of the row. That sort of thing.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Exactly!!
That's what I done now and it's working. I made column defintions and then made the first column as DataKey column (for another purpose). The column also made as visible = false. The paging also working properly.
Thanks a lot Christian.
Success is the good fortune that comes from aspiration, desperation, perspiration and inspiration.
|
|
|
|
|
Hi,
I was wondering if retrieving the input in MVC is always string based?
Like requesting.form a "select multiple" (aka listbox)..
Is any other method than retrieving the values in a comma-separated string? Like "043,015,091"
Or for example a checkbox.. is it possible to retrieve a bool instead of parsing a string?
Because everything must be retrieved by using Request.Form
Please notice that i'm talking about ASP.NET MVC: That means i'm retrieving the values from a controller (POST) and not in the SomeButton_Click or something. In a NOT MVC way it would be all object oriented by using asp controls and etc.
|
|
|
|
|
Sounds like MVC sucks.
A website posts everything as a string. So, a string is all you will ever get. That's how the web works, it has nothing to do with MVC or ASP.NET.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
But with checkboxes, for example, when you use ASP.NET (not mvc) you can manage them as if their were winforms checkboxes (ie. myCheckBox.Value is bool),
And with Listboxes, you can refer to the ith item in the list (because its an array), and so on..
|
|
|
|
|
Because ASP.NET converts it all for you. Which is why I said, it sounds like MVC sucks.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian Graus wrote: Because ASP.NET converts it all for you. Which is why I said, it sounds like MVC sucks.
Seriously. MVC is like a step backwards. I haven't had any problems with ASP.Net, I don't understand what issues MVC fixed. Really, I don't get it even a little bit.
I didn't get any requirements for the signature
|
|
|
|
|
MVC solves the separation of concerns.. thats what it "fixes"
|
|
|
|
|
Christian Graus wrote: Which is why I said, it sounds like MVC sucks.
A broad statement that can fit any number of situations, tools, technologies, etc.
sounds like [insert name here] sucks.
only two letters away from being an asset
|
|
|
|
|
Well, I only have his description to go on, so that is what I was commenting on.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian Graus wrote: Sounds like MVC sucks.
Not in all aspects.
It is good if you want better testability, reduced payload, meaningful URLs and many other things. Two things which I don't like about ASP.NET MVC are, writing markup and server side code together like we did in old ASP and installations on IIS6. Installation on any IIS versions prior to 7 is not very straightforward.
|
|
|
|
|
Hi
I am building an asp.net web application using visual studio 2008 with .NET 3.5 on Windows XP 32 bit machine where I have the server as well. C# and javascript are used.
There is contactUs.aspx, once the form is submitted successfully, I want to run the jQuery in the contactUs.js file starting from line 20 (var dataString = 'name=' + name + '&email=' + email;) to line 40 (return false;).
How do I wire it up.
contactUs.aspx.cs
<pre>
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class contactUs : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
try
{
totalCareAutoTableAdapters.ContactUsTableAdapter ContactUsAdapter = new totalCareAutoTableAdapters.ContactUsTableAdapter();
int new_ContactUs = Convert.ToInt32(ContactUsAdapter.InsertContactUs(name.Text, mobileNumber.Text, emailAddr.Text, subjectTitle.Text, messege.Text));
}
catch (Exception ex)
{
}
}
}
</pre>
contactUs.js
<pre>
/// <reference path="jquery-1.3.2-vsdoc2.js" />
$(function()
{
$('.error').hide();
$(".button").click(function()
{
// validate and process form here
$('.error').hide();
var name = $("[id$='name']").val();
var email = $("[id$='emailAddr']").val();
if (name == "")
{
$("[id$='name_error']").show();
$("[id$='name']").focus();
return false;
}
var dataString = 'name=' + name + '&email=' + email;
$.ajax({
type: "POST",
url: "siteMap.aspx",
data: dataString,
success: function()
{
$("[id$='contact_form']").html("<div id='message'></div>");
$("[id$='message']").html("<h2>Contact Form Submitted!</h2>")
.append("<p>We will be in touch soon.</p>")
.hide()
.fadeIn(1500, function()
{
$("[id$='message']").append("<img id='checkmark' src='images/fiat.jpeg' />");
});
}
});
return false;
});
});
</pre>
|
|
|
|
|
Well, once postback has occured, your page will be rerendered, and the javascript will be able to run. If you need to run a specific method after a specific postback, inject a method call into the page so it runs when rendered.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
To begin with I AM NOT AN ASP.NET Coder. So please bear with me and my questions.
I have to build this in asp instead of silverlight so it can be accessed on blackberries.
I have a page that collects a ton of data about where a link will be started.
The engineers then construct 4-8 links to the endpoint terminus.
What I'm trying to do is have each link get added to the list of links until they click the done button.
Each 'link' in the list would be as follows:
lable'Leg ' lable'nn' text' ' button[next link] button[done]
the lable with the 'nn' value is populated by me and is 1, 2, 3, 4, etc.
the button with [next link] would trigger adding the next set of lables, textbox, and buttons.
the button with [done] would populate the database with all of the links.
In a prior post I was given invalid control types to use and the person never answered me after that.
So how would I do this in ASP.Net so that the input is always sent back to me and the next link is added to the list with each postback?
|
|
|
|
|
A few ways you could do it.
Use a repeater control with a template that contains the label the textbox controls
Pseudo code here
<repeater>
<template>
<label>
<textbox>
</template>
</repeater>
<button value=Next><button value=Done>
Bind the repeater to some collection. Handle the click event for the button and add an item to the collection, then rebind to the repeater.
Another way is to handle the click event for the button and add the next set of controls to the controls collection of the page.
only two letters away from being an asset
|
|
|
|