|
Whats the reasoning behind using javascript?
Why not use c#?
If you are going to use c# its easy just set the checkbox as autopostback and then when postback dropdownlist.enabled = true
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
the reason postback method i dont want
Thanks & Regards,
Member 3879881,
please don't forget to vote on the post
|
|
|
|
|
Member 3879881 wrote: the reason postback method i dont want
Then you should use AJAX .
cheers,
Abhijit
|
|
|
|
|
i m using asp.net.
there is 2 master page in my application say MasterPage11 and Masterpage22.
if i set masterpagefile = MasterPage11 for my content page then code written in content page works well.
but if i change masterpage of same content page as masterpagefiel = Masgerpage22 then code in content page do not execute i.e code written for linkbutton in content page do not execute also gridview page index changin event is not working.
when i click on any link on page it gives massege on status bar as "error on page" and after double click on error it display the error "object does not support this property or method".
is there any problem with masterpage22 ????/
|
|
|
|
|
a.saurabh wrote: is there any problem with masterpage22 ????
I dont know, is there??
This sounds weird
Make sure that the names of the contentplaceholders are the same for both masterpages
And if you are accesing any property or control in the masterpage from the contentpage, it should be on both masterpages or it wont work
Alexei Rodriguez
|
|
|
|
|
When you are chaning master page from MasterPage11 To MasterPage22 . Did you change the ContentPlaceHolder Name Also. I think there are some problem while changing the name. please check on that.
cheers,
Abhijit
|
|
|
|
|
hy,
how can i lock a particular row of a table in the data base (sql server 2005)when i am working on it...its like locking a account while making a transasction so that no other user can make a transaction concurrently.
|
|
|
|
|
This works
begin tran
update table1 set col1 = col1
......now user hase exclusive lock until you either update or commit the transaction, BUT it does mean nobody else can read the record until the commit/rollback, which could ba a long time - for example user goes to lunch. VERY BAD PRACTICE.
Normally you have a column on your table, (usually a timestamp or sequence number) and you read it before applying changes to ensure the record has not changed since the original read.
Hope this helps
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Quite true, one observation though:
Depending on database settings, other users can read the original data while X-lock is on the row.
SQL Server uses nowadays multiversioning like for example Oracle. However, if I remember correctly, it's not enabled by default.
The need to optimize rises from a bad design
|
|
|
|
|
Check this out:
Lock
Lock2
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
Hi,
I want to autocomplete the textbox value according to the listbox items in .net 2.0. Please give me an idea to implement this.
Thanks.
|
|
|
|
|
Do you mean you want somone to click on the listbox and then the value from the listbox appears in the textbox?
If so this is fairly simple as you just set the listbox to AutoPostBack = True and on the Postback take the selected value and put it in the textbox.
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
|
hy,
can any one tell me that how can i read the contents of a MS word(.doc) file on a webpage(.aspx page).
i tried to use filestream but whenevr i run it..i get a option to open or download the doc file which resluts in opening the word file but not the content of the word file on the web page.
the code that i used was
Response.ContentType = "application/ms-word";
Response.AddHeader("content-disposition", "attachment; filename=SFA & CRM.doc");
string a = Server.MapPath("SFA & CRM.doc");
FileStream sourceFile = new FileStream(a, FileMode.Open);
long FileSize;
FileSize = sourceFile.Length;
byte[] getContent = new byte[(int)FileSize];
sourceFile.Read(getContent, 0, (int)sourceFile.Length);
sourceFile.Close();
Response.BinaryWrite(getContent);
plz helpl me out..
regards
modified on Friday, October 10, 2008 4:00 AM
|
|
|
|
|
Hi,
Please know that Word .doc files are in a proprietary Microsoft binary format. They can only be interpreted correctly by the Office Word engine or a third party control suited for this purpose.
You may consider using the Office PIA (Primary Interop Assemblies), automate Word and open the document in it, and extract the relevant portions from the same, preserving the formatting.
Hope this helps.
Regards,
John Adams
ComponentOne LLC
|
|
|
|
|
I have been developing web site run on IIS and Internet Explorer 6.0. When That site run different browser 7.0 or 8.0 or opera then Designing view probleam
modified on Friday, October 10, 2008 1:51 AM
|
|
|
|
|
This is normal. Thats why web developers spend hours working around cross-browser compatability issues.
All you can do is make changes to your css to get round it.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Hi all,
Can anybody help me out in using listbox items in the where clause of a SQL Query like "Select * from TableName where ColumnName In(Listbox Items)"
Thanks in advance
|
|
|
|
|
You can create a stored procedure and then in your c# set the value of the column name to Listbox.SelectedItem.Text
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
We have several PDF forms that we use, which call a submit.aspx to do some emailing of the form data as well as document storage (ImageRight).
Every time we submit the PDF, it calls the Page_Load sub twice. I realize this COULD be an Adobe issue but we're not getting much response from them and I feel there might be some way to check why it's happening in the code and capture it so we can stop the second process.
Anyone else ever see this problem?
|
|
|
|
|
If the Page_Load method is written in VB and it has a 'Handles' clause and also you have 'AutoEventWireup' set to 'true' on the aspx page, then Page_Load will fire twice. ('AutoEventWireup = true' causes all methods starting with "Page_" to be interpreted as event-handling methods for the corresponding page event).
If this is the case, either drop the 'Handles' clause or set 'AutoEventWireup' to false.
David Anton
http://www.tangiblesoftwaresolutions.com
C++ to C# Converter
C++ to VB Converter
C++ to Java Converter
VB & C# to Java Converter
Java to VB & C# Converter
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: convert VB, C#, or Java to C++/CLI
|
|
|
|
|
I’m getting an intermittent false negative on the call “if (!System.IO.Directory.Exists(folder))” in code in an ASP.NET 2 web site [1]. The folder clearly exists, and even contains a log file that is written to when the CLR doesn’t lie about the folder’s existence. Any help would be appreciated.
[1] BugTracker.NET
|
|
|
|
|
Hi All,
I an working on a website and I am trying to implement a tabbed form in ASP .NET.
I did like following in .aspx page:
<asp:menu id="Menu1" width="165px" runat="server" orientation="Horizontal" staticenabledefaultpopoutimage="False" onmenuitemclick="Menu1_MenuItemClick" xmlns:asp="#unknown">
<items>
<asp:menuitem text="" value="0">
<asp:menuitem text="" value="1">
<asp:multiview id="MultiView1" runat="server" activeviewindex="0" xmlns:asp="#unknown"> <asp:view id="Tab1" runat="server">
Contents of the Sub form
<asp:button id="cmdAdda" runat="server" text="Add the Record" tabindex="13">
|
<asp:view id="Tab2" runat="server">
Contents of the subform
<asp:button id="cmdAddb" runat="server" text="Save the Record">
|
And the code in vb .net is:
Protected Sub Menu1_MenuItemClick(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.MenuEventArgs) Handles Menu1.MenuItemClick
Dim i As Integer
MultiView1.ActiveViewIndex = Int32.Parse(e.Item.Value)
i = e.Item.Value
Label2.Visible = False
If (i = "0") Then
Me.Menu1.Items(0).ImageUrl = "~/selectedtab_app.gif"
Me.Menu1.Items(1).ImageUrl = "~/unselectedtab_tut.gif"
ElseIf (i = "1") Then
Me.Menu1.Items(0).ImageUrl = "~/unselectedtab_app.gif"
Me.Menu1.Items(1).ImageUrl = "~/selectedtab_tut.gif"
End If
End Sub
The problem is that when I click on the second tab, it is not getting clicked ( the value of i is not being 1 so that the next sub-form is not getting shown).
I am highly seeking for help.
Thanks,
|
|
|
|
|
Hi,
I get inputs from a formview and then place the data inside a listview via an ObjectDatasource. The binding is a "two way binding" for every control in formview. However when I insert data, the listview doesn't show anything, just adding empty rows.
I decided to check if data was reaching to ObjectDataSource_Inserting procedure and the answer was "YES". I wonder why? Do I have to add data manually inside the Listview_ItemCreated or Listview_ItemInserting procedures? I thought that there was no need to do it. What template should I use in listview for just displaying data? I have used ItemTemplating.
If you enlighten me about the solution, I would appreciate it.
Thanks.
What a curious mind needs to discover knowledge is noting else than a pin-hole.
|
|
|
|
|
Friends,
I'm preparing a quiz in asp.net using sql server 2005 as backend.
Now i want two things in that
1. a timer - i'm trying from last 3 days and used all methods given in asp.net
2. dynamically create panels - tried also this but no way find to create that.
help me out
|
|
|
|