C# Question regarding rewriting from VB -


i'm vb guy learning c#. seem getting hang of i've got couple questions regarding code i'm writing.

in first 1 here i'm getting error when write code so:

irowindex = sf1411bindingsource.find(sf1411dataset.sf1411.columns(groupbox4.tag.tostring).tostring, textbox1.text);         if (irowindex == -1) 

error 1 'system.data.datatable.columns' 'property' used 'method' c:\11180_application\11180_application\edit.cs 186 71 11180_application

my other issue in vb use tags in c# doesnt seem them:

//set find label display new find column groupbox4.text = "find - " + sender.tag.tostring + ":"; //store sort column name in lblfind's tag property groupbox4.tag = sender.tag.tostring; 

error 4 'object' not contain definition 'tag' c:\11180_application\11180_application\edit.cs 211 36 11180_application

any ideas here?

try columns[groupbox4.tag.tostring()] first error.

regarding tags, in c# sender of type object, , doesn't have tag property. try casting control first:

((control)sender).tag 

Comments

Popular posts from this blog

c++ - Convert big endian to little endian when reading from a binary file -

C#: Application without a window or taskbar item (background app) that can still use Console.WriteLine() -

unicode - Are email addresses allowed to contain non-alphanumeric characters? -