Home > Net >  How to use vb code in c #, adodc controls?
How to use vb code in c #, adodc controls?

Time:10-05

Vb source code:
With adodc1
If. You. BOF=True Then Exit Sub
. You. MoveFirst
Wrdapp. Selection. MoveRight unit:=wdCell, Count:=3
Wrdapp. Selection. TypeText Text:=) you! The Date
Wrdapp. Selection. MoveRight unit:=wdCell, Count:=1
Wrdapp. Selection. TypeText Text:=) you! Type
Wrdapp. Selection. MoveRight unit:=wdCell, Count:=1
Wrdapp. Selection. TypeText Text:=) you! The Result
. You. MoveNext
Could you tell me how to turn this turn a c #, especially read adodc1 a column element that oneself change section of the diagram below, one is datPrimary adodc controls, but has been an error, a great god teach

CodePudding user response:

{
Var withBlock=adodc1;
If (withBlock. You. BOF==true)
return;
WithBlock. You. MoveFirst ();
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 3);
Wrdapp. Selection. TypeText (Text: withBlock. You. Date);
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 1);
Wrdapp. Selection. TypeText (Text: withBlock. You. Type);
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 1);
Wrdapp. Selection. TypeText (Text: withBlock. You. Result);
WithBlock. You. MoveNext ();
}

CodePudding user response:

reference 1st floor ManBOyyy response:
{
Var withBlock=adodc1;
If (withBlock. You. BOF==true)
return;
WithBlock. You. MoveFirst ();
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 3);
Wrdapp. Selection. TypeText (Text: withBlock. You. Date);
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 1);
Wrdapp. Selection. TypeText (Text: withBlock. You. Type);
Wrdapp. Selection. MoveRight (unit: wdCell, Count: 1);
Wrdapp. Selection. TypeText (Text: withBlock. You. Result);
WithBlock. You. MoveNext ();
}
big brother, how are you doing this code is to use online language converter to turn right, it won't work,
  •  Tags:  
  • C #
  • Related