473,320 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Is there any way to know whether a procesure parameter is paramarr

Using reflection, is there a way to know that a method or property parameter
is a paramarray? There doesn't seem to exist a property like 'IsParamArray'
in reflection.parameterinfo.

Thanks in advance.
Jul 21 '05 #1
2 1223
Yes, check the ParamArrayAttribute:
....
ParameterInfo[] Param = callMethod.GetParameters();
for(int i = 0; i < Param.Length; i++)
{
if(Attribute.IsDefined(Param[i], typeof(System.ParamArrayAttribute)))
Debug.Write(Param[i].Name + " is a paramarray");
}
Jul 21 '05 #2
Thank you, great help.
Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: vishal | last post by:
Hi, I am writing my first script to execute a Oracle procedure through a unix script. Could you tell me how do I do error handling here? How do I know in my script if the procedure executed...
10
by: Eitan | last post by:
Hello, I want to know, wheter an asp (that call itself in "get" method, has passed any parameter to itself). i.e : in the asp : test_asp.asp : ..... <html> <body>
2
by: Dan | last post by:
How does one do this?
2
by: Ben Taylor | last post by:
Hi, I am writing a program that uses different threads to handle various painting operations, I wondered if somebody could possible tell me if I create a new thread using...
2
by: David Krussow | last post by:
The 2nd parameter of the method controls whether a persistent cookie is created - so that ASP.NET can "know" if the current user has been previously authenticated (during previous browser...
11
by: ItsMe | last post by:
Hi, I've 50 MDI Forms in my project, so trying to create MDI Child Form from this procedure. But the problem is, unable to declare as "NewFormName". It gives me an error. Is there any other...
4
by: Rodger Dusatko | last post by:
After entering the sql statement da.deletecommand.commandtext = "Delete from Users where username = @username" I set the parameter to the username I wish to delete. This successfully deletes the...
2
by: buzzy | last post by:
Using reflection, is there a way to know that a method or property parameter is a paramarray? There doesn't seem to exist a property like 'IsParamArray' in reflection.parameterinfo. Thanks in...
1
by: yuchang | last post by:
Hi, Using the FormView control is very efficient. But I want to do some action,like showing a success message or redirect to another page, after inserting, updating and deleting. How do I get...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.