cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a method with ByRef parameter

Former Member
0 Kudos

Hi All,

when i am creating a method with parameter as ByRef, i am getting the message as fallows.

Please use valid signature.

help me to overcome frojm this.

Thanks in advance.

With Regards

Raju

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi,

By any chance the parameters passed are "property parameters"??. If they are i dont think VB.net will support them. Please check that.otehrwise i feel this shuld work.

Thanks,

Abishek

Former Member
0 Kudos

Hi ,

when i am creating the function with ByRef parameters it is creation.

but when i am creating with key word sub with ByRef parameters it is not creating,

it is saying pls provide currect signature,

Thanks in advance,

With Regards,

Raju

Former Member
0 Kudos

Hi,

strange... I even thought that ByRef is default parameter type for sub... maybe you can try this.

Or try to create your sub directly in the project file, maybe then you will have a proper error message from MS.

Regards,

Wolfhard

Former Member
0 Kudos

Hi Wolfhard,

Exactly.

I want to create a custom method with ByRef parameters.

Thanks in Advance.

With Regards,

Raju

Former Member
0 Kudos

Hi,

is this your first own method (i.e. was it working before), and is it working for ByVal parameters?

And did you already reserve the customer namespace (Y or Z)?

Regards,

Wolfhard

Former Member
0 Kudos

Hi abishek,

Thanks for your input.

but i am not creating event handler, just i am creating a method.

here is my method look like.

Public Sub SetCopyDefaults( ByRef objSdgen As BusinessObject, ByRef strCopyTypeTmp As String)

Thanks in advance.

With Regards,

Raju

Former Member
0 Kudos

Hi,

I guess you want do define your method in your customer name space like Z_XXX, right?

Regards,

Wolfhard

Former Member
0 Kudos

Hi Raju,

Make sure you have necessary "Handles" clause present

eg: Private Sub mCore_beforeUnload(ByRef cancel As Boolean) Handles mCore.beforeUnload (mcore here is the tile or tileset )

Thanks

Abishek