Click here to Skip to main content
15,899,314 members
Home / Discussions / C#
   

C#

 
GeneralRe: how to identify my screen data? Pin
neodeaths27-Sep-11 20:46
neodeaths27-Sep-11 20:46 
GeneralRe: how to identify my screen data? Pin
Eddy Vluggen28-Sep-11 7:33
professionalEddy Vluggen28-Sep-11 7:33 
GeneralRe: how to identify my screen data? Pin
Pete O'Hanlon28-Sep-11 8:11
mvePete O'Hanlon28-Sep-11 8:11 
Questionquestion about programming for interacting with my desktop controls Pin
neodeaths26-Sep-11 23:43
neodeaths26-Sep-11 23:43 
AnswerRe: question about programming for interacting with my desktop controls Pin
André Kraak27-Sep-11 2:06
André Kraak27-Sep-11 2:06 
QuestionMarshal an int array with unkown length at class construction Pin
Member 788975126-Sep-11 23:38
Member 788975126-Sep-11 23:38 
AnswerRe: Marshal an int array with unkown length at class construction Pin
BobJanova27-Sep-11 0:38
BobJanova27-Sep-11 0:38 
GeneralRe: Marshal an int array with unkown length at class construction Pin
Member 788975127-Sep-11 2:21
Member 788975127-Sep-11 2:21 
the structure is directly used in the API provided with the PLC. This is the declaration of the wrapper:

C#
//
     // Summary:
     //     Writes an object synchronously to an ADS device.
     //
     // Parameters:
     //   variableHandle:
     //     Handle of the ADS variable.
     //
     //   value:
     //     Object to write to the ADS device.
     public void WriteAny(int variableHandle, object value);


and my call to it is:

C#
/// <summary>
       /// Set all IO ports LOW
       /// </summary>
       public void SetAllLow()
       {
           for (int i = 0; i < iNrIO; i++)
               _PinStructureQuality.iPinValues[i] = (int)(65535);
           try
           {
               if (e._ErrorCode == 0)
                   adsClient.WriteAny(hcomplexStruct, _PinStructureQuality);
           }
           catch
           {
               e._ErrorCode = 1;
               e._ErrorMessage = "Could not write pinning data to PLC";
               ErrorEvent(this, e);
               e._ErrorCode = 0;
               e._ErrorMessage = "";
           }
       }



The reason I want to use this WriteAny call is that it allows me to sent also strings and other types in the same structure.
AnswerRe: Marshal an int array with unkown length at class construction Pin
jschell27-Sep-11 8:02
jschell27-Sep-11 8:02 
AnswerRe: Marshal an int array with unkown length at class construction Pin
DaveyM6927-Sep-11 10:41
professionalDaveyM6927-Sep-11 10:41 
Questiondownload a file which is in Network location( \\10.101.....) Pin
venu65626-Sep-11 19:12
venu65626-Sep-11 19:12 
AnswerRe: download a file which is in Network location( \\10.101.....) Pin
BobJanova26-Sep-11 22:16
BobJanova26-Sep-11 22:16 
GeneralRe: download a file which is in Network location( \\10.101.....) Pin
venu65627-Sep-11 21:25
venu65627-Sep-11 21:25 
GeneralRe: download a file which is in Network location( \\10.101.....) Pin
BobJanova28-Sep-11 7:33
BobJanova28-Sep-11 7:33 
QuestionCode Generator Project. Help deciding if I should publish it. Pin
Armando de la Torre26-Sep-11 18:13
Armando de la Torre26-Sep-11 18:13 
AnswerRe: Code Generator Project. Help deciding if I should publish it. Pin
Mycroft Holmes26-Sep-11 19:50
professionalMycroft Holmes26-Sep-11 19:50 
GeneralRe: Code Generator Project. Help deciding if I should publish it. Pin
Armando de la Torre26-Sep-11 21:40
Armando de la Torre26-Sep-11 21:40 
GeneralRe: Code Generator Project. Help deciding if I should publish it. Pin
Mycroft Holmes26-Sep-11 22:00
professionalMycroft Holmes26-Sep-11 22:00 
GeneralRe: Code Generator Project. Help deciding if I should publish it. Pin
Pete O'Hanlon26-Sep-11 22:38
mvePete O'Hanlon26-Sep-11 22:38 
GeneralRe: Code Generator Project. Help deciding if I should publish it. Pin
Armando de la Torre28-Sep-11 10:11
Armando de la Torre28-Sep-11 10:11 
AnswerRe: Code Generator Project. Help deciding if I should publish it. Pin
PIEBALDconsult27-Sep-11 2:50
mvePIEBALDconsult27-Sep-11 2:50 
QuestionLiinking two web pages Pin
Jomon T Jose26-Sep-11 16:50
Jomon T Jose26-Sep-11 16:50 
AnswerRe: Liinking two web pages Pin
Mycroft Holmes26-Sep-11 17:22
professionalMycroft Holmes26-Sep-11 17:22 
GeneralRe: Liinking two web pages Pin
Jomon T Jose26-Sep-11 17:24
Jomon T Jose26-Sep-11 17:24 
AnswerRe: Liinking two web pages Pin
ScottM126-Sep-11 20:34
ScottM126-Sep-11 20:34 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.