|
Hi,
I am using an ActiveX control in a web page, when a button is clicked the control is executed in java script code, Before executing the control, the system is displaying a prompt message that:
An activeX control on this page might be unsafe to interact with other parts of the page, Do you want to allow this interaction.
is there any way to disable such prompts.
Thanks in Advance
|
|
|
|
|
Yes, get the user to disable them. This is a security feature, you can't just turn it off remotely
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi,
Is it possible to have a combobox in ASP.Net were a user can enter new values or edit the existing values.
I searched via google but am not getting the simplest way to do this.
Am new to ASP ,any help will be welcome.
Any links or ideas are welcome.
Many Thanks
|
|
|
|
|
I doubt it. You could do some javascript to alternate between a textbox and a dropdownlist, but I don't think a HTML drop list is ever editable.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi All,
I want to access server controls using javascript in web user controls. I tried it by using "i=document.all.txtActualCost.value;" statement. But it is giving error. Please can anybody help me.
Thanks,
Aleem Mohammad
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
Your first port of call ( apart from google ) should be to look at the actual HTML being generated. ASP.NET generates unique client side names. That means the server side name is not it.
On the server side, txtActualCost has a property called ClientID. Emit some script that stores this value for the client side and use that.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi Christian,
I have tried it too, by using the i=getElementByID("txtActualCost").value;. It is too giving error. And not getting much support from google too. Please can any body help me.
Thanks,
Aleem Mohammad
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
Please read what I told you. What you're doing, won't work, for the reason I just explained. Please do what I suggested - look at the HTML and you'll see what it's called on the client. The nasty hack is to copy that value, the right way is to use the ClientID property to write out the right string into your javascript.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Sorry christian I got it. And became busy thats why I didnt inform you yaar. Sorry.
Aleem Mohammad.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
indian143 wrote: i=getElementByID("txtActualCost").value
As CG suggested, use ClientId . If your server control is in a user control, ASP.NET prefixes the user control's id with the control id. So your getElementById('ControlName') won't work. Use ClientId instead.
var controlId = '<% ControlId.ClientId %>';
var controlObject = document.getElementById(controlId);
|
|
|
|
|
I got it Navaneeth, but why document.getElementById() function is not working at my machine. I guess its browsers version problem. At clients place how can we solve this problem. Can you please suggest me yaar.
Thanks,
Aleem Mohammad.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
indian143 wrote: but why document.getElementById() function is not working at my machine
As I told, use ClientId instead. Appending container id with control's id is a ASP.NET mechanism to keep control id unique throughout the page.
|
|
|
|
|
When I began the programming for http://www.sceptermarketingtechnologies.com, I quickly noticed that Asp.net does not support the MessageBox class that I was familiar with in windows forms.
Since Asp.net runs on the server it doesn't have access to produce a modal dialog box on the client. However, by using a scripting language that runs in the clients browser a similar construct is available. In javascript the window.alert() function will produce a modal dialog similar to what you would expect from MessageBox in windows forms.
So, I decided to create a static class MessageBox with a static method Show(), which will give you the ablility to to still use the syntax MessageBox.Show("Your Message"); and then convert it into the javascript window.alert("Your Message"); and add the script to the end of the current response stream.
I've written a how to on my blog at: http://sceptermt.blogspot.com/2008/02/how-to-create-message-box-class-in-c.html that shows the source code that I used in C# for my web application and details on how it works.
You could also write overloads for the static show() method to allow the class to do a javascript confirm() or a prompt(). I haven't needed that functionality yet so I've just kept it simple.
|
|
|
|
|
We have articles on this site. Sounds like you're looking to write one ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi,
I am new to ASP .NET and I am creating an e-exam website for a customer, the customer will have at most 50 students taking an exam simultanously.
I want to create a Microsoft Jet (Access) database (.mdb), but I know that Access database format is not designed to be used in websites where concurrency is an issue.
The question is:
Can Microsoft Access database files bear the load of 50 students submitting their answers almost at the same time or do I need an SQL server database? I don't know but I think that 50 users is a very small load even for this kind of database.
Any answers?
Thanks
And ever has it been that love knows not its own depth until the hour of separation
|
|
|
|
|
Mohammad A Gdeisat wrote: I am new to ASP .NET and I am creating an e-exam website for a customer
It's only a matter of time before the backlash starts because of people who take on clients in technologies they are new to.
I would say go with SQL Server. According to google[^], 10 is the limit for the Jet engine, even across different apps. That doesn't mean that you can even have 10 concurrent users for an Access DB, let alone 50.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Ok, now my client wants to install the website on his own server (in the school). The server is running Windows XP.
Does my client need to install any applications (other than IIS) to make the website work with SQL server database?
Thanks
And ever has it been that love knows not its own depth until the hour of separation
|
|
|
|
|
I recommend reaing this[^].
No, he doesn't need anyting else, but for 50 users, he's going to have to buy SQL Server, I believe that's more than the Express Edition will support.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I just have one more question about the same issue.
I don't want my client to buy SQL server (if possible), so I would suggest myself to place the code that tries to connect to the database in a loop that checks whether the connection has succeeded or not, if it succeeds then it will update the database, if not, then it will try to connect again and again until it succeeds and then update the database, and so on.
Does this solve part of the issue or is it a BAD solution?
Thanks
And ever has it been that love knows not its own depth until the hour of separation
|
|
|
|
|
I guess it depends. He's probably paying you little enough that if you can handle the work, writing some sort of caching that does the DB updates when the DB is free, may be a viable solution. It's a hack tho. You still will be using a tool that's not suited to the task, when 50 students make a request that takes some time, if they all have to wait their turn, you risk web pages timing out, and your app breaking.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Only 2 out of our 190 client sites use full SQL Server. There are no more connection limits on 2005, just CPU and RAM, so for a standard DB, without additional services, there is nothing wrong with Express for 50 users.
|
|
|
|
|
Christian Graus wrote: only a matter of time before the backlash starts because of people who take on clients in technologies they are new to
Yep.
Christian Graus wrote: 10 concurrent users for an Access DB, let alone 50
A client of mine uses Access with about 10-15 concurrent and I've warned them about consequences of overloading the database. They want to add a few more people, and we'll see
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
Why not use SQL Server 2005? Access may run into trouble with more than 10 concurrent users.
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
My client will install the website in his local server that runs WinXP, and I don't think that he will buy SQL server. He wants to run the application only in his local network, and I guess that the application is too small to deserve buying SQL server..
I would support your comment if my clien wants to install the website on a public web server because he will have to pay nothing, but buying SQL server for this application for which he paid me $1400 is not an option.
Thanks
And ever has it been that love knows not its own depth until the hour of separation
|
|
|
|
|
Mohammad A Gdeisat wrote: for which he paid me $1400
OK then....
MySQL is always an option and there are other DBs out there. MySQL may even be free ( check the license ), because he's a non commercial user.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|