|
Hi,
I need to enable Profile in my ASP.NET 2.0 web app.
In order to enable it I followed the next steps:
1. manually created the sql profile tables using the aspnet_regsql -A all command
2. enabled authentication from the web.config file
<authentication mode="Forms">
<forms loginurl="~/auth/login.aspx" timeout="60" protection="All">
<authorization>
<allow users="*">
3. configured the profile provider
<connectionstrings>
<add name="devProfileProvider" providername="System.Data.SqlClient" connectionstring="server=myServer;database=aspnetdb;User Id=sa_dev;Password=devPass;Connection Lifetime=3600;Min Pool Size=10;Application name=mySite">
and
<profile enabled="true" defaultprovider="myProfileProvider">
<providers>
<clear>
<add name="myProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionstringname="devProfileProvider" applicationname="mySite">
<properties>
<add name="MyProp" type="String" defaultvalue="Andrei">
4. defined profile properties - see above
From what I've read so far about Profile in ASP.NET that should be enough to start working with the profile in my web app, but currently I am not able to work with it. I don't have access to any of my properties and I don't have access to the Profile object.
Can anyone see any mistake in the steps I've made or should I perform some extra configuration for my application?
What do I need to do in order to work with the profile?
Thanks in advance!
Andrei
|
|
|
|
|
|
I have a listview control that is bound to a datasource. I want to total the values in one of the columns. How do I get to the desired value? I thought it would be a simple matter to add an event handler for ItemDataBound , but I haven't been able to figure out how to get to the item's data.
Any help?
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Its a bit convoluted to be honest John. You have to first check that the item is a DataItem, and if it is then cast to ListViewDataItem then cast the dataitem to your object.
here's a bit of test code:
private int total = 0;
protected void ItemDataBound(object sender, ListViewItemEventArgs e)
{
if (e.Item.ItemType == ListViewItemType.DataItem)
{
ListViewDataItem item = (ListViewDataItem)e.Item;
Thing thing = (Thing)item.DataItem;
total += thing.Value;
}
}
I got summing to work nicely on my ListView in a simple test project, if you need the full code just holler.
|
|
|
|
|
Yeah, that's what I discovered (and it's even more convoluted than that). What a pain in the ass.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I am trying to total my listview, but can't seemed to get it. If you still have your test code and don't mind sharing, you can email it to me at thegoose78@yahoo.com. I am using VB.NET, but should be able to convert it from C#.
I am able to sum by columns going across, but can't get the rows going down.
Any help greatly appreciated.
Thanks
|
|
|
|
|
hi,
i have a DataGridView with manually generated columns.
i have a template column named "DueDate".
for this column i am using a WebUserControl consists on an asp Calendar and a text box that shows the chosen date, for saving the data of the selected date i'm using the Session object.
the problem i have is with the EditItemTemplate. i cant manage to get the data i need for showing the target date in the WebUserControl TextBox.
i've created a Text property for the control and tried to fill it as follow but it doesn't work:
<EditItemTemplate>
<uc1:ctrldatepicker text="<%# DataBinder.Eval(Container.DataItem, " duedate=")%>" id="CtrlDatePicker1" runat="server" xmlns:uc1="#unknown" />
</EditItemTemplate>>
also have tried:
<EditItemTemplate>
<uc1:ctrldatepicker text="<%# Session[" targetdate="].ToString())%>" id="CtrlDatePicker1" runat="server" xmlns:uc1="#unknown" />
</EditItemTemplate>>
didnt work also
anyone can help me on that?
thanks in advance
j
|
|
|
|
|
In a table, I have stored a following path
"d:\image\img\abc.jpg"
My requirement is I only want to print "abc.jpg"
I use datalist, and in datalist i take LinkButton from toolbax.
I use following queryin asp.net. but this code does not work.
protected void Page_Load(object sender, EventArgs e)
{
string s = "select * from image";
SqlDataAdapter da = new SqlDataAdapter(s, con);
DataSet ds = new DataSet();
da.Fill(ds, "a");
string ph = null;
string ab = null;
ph = ds.Tables[0].Rows[0]["img"].ToString();
ab = Path.GetFileName(ph);
dlTiff.DataSource = ds.Tables["a"];
dlTiff.DataBind(); }
please solve it
thanks in advance
|
|
|
|
|
Original is a few posts down
|
|
|
|
|
sorry, I could not understand that what actually you are saying.
please explain if possible
|
|
|
|
|
I would have done, if you didnt vote me down.
|
|
|
|
|
I think u are joking with me. Not helping me.
thanks for not solving my problem
|
|
|
|
|
i use Procedure & and parameters by cookies in my crystal report.but at run time crystal report show
olny two page when i click on next button after 2 page ,third page doesn't display...but if i type pageno in text box and click go botton then third page display...i m not enable to understand this..
so PLZ help me....
|
|
|
|
|
hi
i am using fckeditor as mentioned in hints of google search page. but when i add tool in toolbar. and drag and drop all work done according to the web suggestion but problem is that when i use fckeditor and run page all page is good but fck editor return error message
error message HTTP Error 404 - Not Found.
Version Information: ASP.NET Development Server 8.0.0.0
please tell me what the problem and solution of this problem.
I will do my best?
Integrated Solutions, Bikaner (Raj.), India
|
|
|
|
|
Try contacting the authors of fckeditor, they should be able to help.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
hi all,
i am using asp.net menu control on mysite,menus are two level, but level-1 menus don't have links associated with them, below is scenario explained.
Administrator((level-1) when clicked,page is posted back which i don't want)
---click1 (level-2)
---click2 (level-2)
when level1 item is clicked page is posted back which i dont want as it dont have any target url or link
Regards.
Tasleem Arif
|
|
|
|
|
use
JavaScript:void(0); as terget url. This should solve ur problem
Venky
|
|
|
|
|
I have two aspx forms as the html code given below.
I am having two input boxes in parent window [default1.aspx] and opening a model window [using default2.aspx] and setting the values for this model window from parent window object through window.dialogArguements property.
I am able assign the values to model window.
Now I want to update the parent window, with the values updated from the model window. Plz advice me.
default1.aspx --> parent window
default2.aspx --> model window
My code flows as shown below:
default1.aspx
==========
window.defaultStatus="hai";
function openwin(){
var myObj = new Object();
myObj.fName = inputFName.value;
myObj.lName = inputLName.value;
window.showModalDialog('default2.aspx',myObj,"dialogHeight:400px; dialogWidth:500px;");
}
default2.aspx
===========
<title>It is a Model Window
First Name :
Last Name :
var frmobj;
frmobj = form1.elements;
var myObj = window.dialogArguments;
function loaddata(){
frmobj.receiveFName.value = myObj.fName;
frmobj.receiveLName.value = myObj.lName;
}
function updatechanges(){
myObj.fName = 'aaaa';
}
Muthu
|
|
|
|
|
Hi i am using asp.net in my application. I need to integrate payment options for our clients. what i am telling that if customer choose my product and it cost is 20$. Customer want to buy this product. What i will do at this time?. what is the procedure ?I integrate paypal , verisign or any relavant options ?
Hope ur's reply.
Every Successful Person Have A Painful Story
|
|
|
|
|
The procedure is to read the integration documentation for the payment scheme you go for, be it PayPal, Google Checkout or some other e-Merchant scheme, on their websites. They each have their own way of doing things.
|
|
|
|
|
Hi All,
I have Datagrid which takes data from data source, I Put ItemTemplate and FooterTemplate, the Problem Here I can't access any control in footertemplat regardless the type of control Texbox or others which I used, I need to know how to access any control in FooterTemplat in CodeBehind page.
Regards
Mr.Wonderful
|
|
|
|
|
Iam using one login screen in my project.when i enter the user name and password and click the Button .The button is not firing some times
when i click second time only it fires.
i have written the code in server side only.wat may be the reason for this
can anyone give the solution ?
when i run the project url in any one of my near by system also same problem comes for the first time
|
|
|
|
|
Are you using the asp.net login control? I found this problem in FF but didnt get it in IE for some reason.
The answers posted by me are suggestions only and cannot be used in anyway against me.
|
|
|
|
|
hi,
put causes validation = false and runat = server in button property
Ashok
|
|
|
|
|