Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Button Arrays.

Reply
Thread Tools

Button Arrays.

 
 
MJ
Guest
Posts: n/a
 
      09-11-2008
Hi all, not sure if this is the right forum,but I'd like to create an array
of Radio Buttons for a web page.

I understand how to create an array, but I need one for RB specifically and
know how to access them.

Searching the web is great, but I'm winding up with too many pages that take
me off on a winding road, with no precise solution.

Any help would be appreciated.

Thanks.


 
Reply With Quote
 
 
 
 
Evertjan.
Guest
Posts: n/a
 
      09-11-2008
MJ wrote on 11 sep 2008 in microsoft.public.inetserver.asp.general:

> Hi all, not sure if this is the right forum,but I'd like to create an
> array of Radio Buttons for a web page.


Radio buttons are html objects, an array is a computer language thing.
Perhaps an array of pointers to radio buttons?

but then, ASP is a platform for serverside languages, and radio buttons are
clientside things.

I think you are in the wrong NG.

> I understand how to create an array, but I need one for RB
> specifically and know how to access them.


What is RB?

> Searching the web is great, but I'm winding up with too many pages
> that take me off on a winding road, with no precise solution.


For a precise solution, you need a precise concept,
you did not show one, in my view.

Please shoe some ASP code you have in mind.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
 
Reply With Quote
 
 
 
 
Old Pedant
Guest
Posts: n/a
 
      09-11-2008
"MJ" wrote:

> Hi all, not sure if this is the right forum,but I'd like to create an array
> of Radio Buttons for a web page.


Are you asking for ASP or ASP.NET???

This forum is for ASP (old style), not ASP.NET. And in ASP since there is
no tight coupling between the server code and the client code, your question
is pretty much a non sequitir.

I should also point out that, as rendered in HTML, there's no such thing as
"an array of Radio Buttons". Each button is and must be an independent HTML
control within an HTML <FORM>. Now, it's true that if you give multiple
radio buttons the same name then they are treated as an array by JavaScript
code on the page, but that's not directly an HTML issue. And, further, the
JavaScript array may or may not resemble any array you created on the server.

Again, ASP.NET hides a lot of this. But if you are asking about ASP.NET
then you'd be better off asking in the MSDN forums and/or at www.asp.net
and/or at any of the many other .NET forums.

 
Reply With Quote
 
MJ
Guest
Posts: n/a
 
      09-11-2008
Well of course I am, what a dummy. Don't know what I was thinking.

Thanks. Btw: RB = shorthand for Radio Button.
"Evertjan." <(E-Mail Removed)> wrote in message
news:Xns9B16DCF83A4F3eejj99@194.109.133.242...
> MJ wrote on 11 sep 2008 in microsoft.public.inetserver.asp.general:
>
>> Hi all, not sure if this is the right forum,but I'd like to create an
>> array of Radio Buttons for a web page.

>
> Radio buttons are html objects, an array is a computer language thing.
> Perhaps an array of pointers to radio buttons?
>
> but then, ASP is a platform for serverside languages, and radio buttons
> are
> clientside things.
>
> I think you are in the wrong NG.
>
>> I understand how to create an array, but I need one for RB
>> specifically and know how to access them.

>
> What is RB?
>
>> Searching the web is great, but I'm winding up with too many pages
>> that take me off on a winding road, with no precise solution.

>
> For a precise solution, you need a precise concept,
> you did not show one, in my view.
>
> Please shoe some ASP code you have in mind.
>
> --
> Evertjan.
> The Netherlands.
> (Please change the x'es to dots in my emailaddress)
>



 
Reply With Quote
 
j++coder
Guest
Posts: n/a
 
      10-14-2008
Hi,

i had converted a j++ dll into j# com dll(VS 2005) . In global.asa of
classic asp when i am trying to set the application variable with the dll
object it is not setting up.





Dim o

Set o = CreateObject("MyClass")



Application("myappObj") = o



but if i am setting it at session level then i am able to set it.

i.e.

Session("oo") = acd





I tried to call all these methods from the console application just to make
sure that the dll is build correctly, and it is working fine.





in my main class i have the constructor method defined which i used to
create the instance of other classes

using



MyClass.ConstructClass("ClassName", 1)



in the constructclass method i have the following code

{

Class conClass = Class.forName(ClassName);
Class conParms[] = new Class[5];
conParms[0] = Class.forName("java.sql.Connection");
conParms[1] = Class.forName("java.lang.String");
conParms[2] = Class.forName("java.lang.String");
conParms[3] = Class.forName("java.lang.String");
conParms[4] = Class.forName("java.lang.String");

Constructor ObjConstructor = conClass.getConstructor(conParms);
Object conObj[] = new Object[5];
conObj[0] = this.dbConn;

conObj[1] = new String(this.IPaddress);
conObj[2] = new String(this.Userid);
conObj[3] = new String(this.BR);
conObj[4] = new String(this.SessionID);

return ObjConstructor.newInstance(conObj);

}



if i am using the constructclass method in console application then it is
behaving in the right manner i.e. if a object of some other class is created
using ConstructClass then i am able to call the method's of that class
comfortably but if i am using it in ASP then it is raising an error "Object
required'


 
Reply With Quote
 
Bob Barrows [MVP]
Guest
Posts: n/a
 
      10-14-2008
j++coder wrote:
> Hi,
>
> i had converted a j++ dll into j# com dll(VS 2005) . In global.asa of
> classic asp when i am trying to set the application variable with the
> dll object it is not setting up.
> Dim o
> Set o = CreateObject("MyClass")
>
> Application("myappObj") = o


You left out the "Set" keyword

> but if i am setting it at session level then i am able to set it.
> i.e.
> Session("oo") = acd


If acd is an object, this should not have worked


--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.


 
Reply With Quote
 
j++coder
Guest
Posts: n/a
 
      10-15-2008
thanks for the quick reply.

The set keyword is used but still it is not setting it in Application
variable

Dim o , sLogFileDir
Set sLogFileDir = "c:\log"
Set o = CreateObject("MyClass")
Call o.StartLog (sLogFileDir)
Set Application("myappObj") = o

MyClass is an J# (2005) com visible Dll Class , if it is j++ dll then it is
happening but not with j# dll.




 
Reply With Quote
 
Bob Barrows [MVP]
Guest
Posts: n/a
 
      10-15-2008
j++coder wrote:
> thanks for the quick reply.
>
> The set keyword is used but still it is not setting it in Application
> variable
>
> Dim o , sLogFileDir
> Set sLogFileDir = "c:\log"
> Set o = CreateObject("MyClass")


************************************************
> Call o.StartLog (sLogFileDir)

************************************************

Is this the line that raised the "object required" error? If so, that
indicates to me that
a. You have failed to register the dll on the machine using regsvr32.exe
b. this is not really a COM dll


> Set Application("myappObj") = o
>
> MyClass is an J# (2005) com visible Dll Class , if it is j++ dll
> then it is happening but not with j# dll.


Is it free-threaded? If not, you don't want to be storing it in Application
or Session anyway.

Have you verified that you can use this dll in a COM environment? A simple
..vbs file should be sufficient to tell you this.

--
Microsoft MVP - ASP/ASP.NET - 2004-2007
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


 
Reply With Quote
 
Bob Barrows [MVP]
Guest
Posts: n/a
 
      10-15-2008
j++coder wrote:
> thanks for the quick reply.
>
> The set keyword is used but still it is not setting it in Application
> variable
>
> Dim o , sLogFileDir
> Set sLogFileDir = "c:\log"
> Set o = CreateObject("MyClass")
> Call o.StartLog (sLogFileDir)
> Set Application("myappObj") = o
>
> MyClass is an J# (2005) com visible Dll Class , if it is j++ dll
> then it is happening but not with j# dll.


Oh wait. I just reread your original message and saw that you said you did
successfully store the dll in Session, although that statement is
contradicted by this one:

but if i am using it in ASP then it is raising an error "Object
required'

So maybe it does seem you have a usable COM object. So I guess the only
thing is to establish where in global.asa you are attempting to store it in
Application. Excuse the question, but ... hopefully you put the above code
in the application_onstart event handler sub in global.asa ...

If the above lines are the only lines of code in global.asa, they will never
fire ... you probably knew this already but I have to eliminate all
possibilities

--
Microsoft MVP - ASP/ASP.NET - 2004-2007
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


 
Reply With Quote
 
jai gupta
Guest
Posts: n/a
 
      10-23-2008
Hi

Thanks for the reply.

i do certainly had many things that are set at application level apart
from the above mentioned line.

apart from above issue i have some more :-
1. Whenever i am trying to call the J# com dll overloaded method from
asp it throws the error of Wrong / Invalid arguments error. though if i
change the signature of those
methods they work fine.

2. whenver i try to pass a object in a j# com dll object from asp it
thrwos the error of "Variable uses an Automation type not supported in
VBScript". e.g.
Set o = CreateObject("License")
Set m = CreateObject("MyClass")
Call m.getAllScreens(o)

it throws the above mentioned error.



please help.
thanks in advance.

j++Coder





*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
image button click event fires before click event of button Purvi T ASP .Net 0 10-19-2004 06:19 AM
Image button acting like submit button. Russell ASP .Net 3 06-24-2004 01:55 AM
Button.Init? how Do I know if click event has been fired? TextBox.TextChanged event before Button.Click in a CompositeCustomControl. jorge ASP .Net 2 05-25-2004 11:45 PM
HTML Reset Button Doesn't work after postback with Submit button Chris Lane ASP .Net 4 11-17-2003 11:52 PM
JavaScript Access to Button in form tags (webcontrol or html button) Wes Weems ASP .Net 1 07-20-2003 05:27 AM



Advertisments