Поделиться через


IPacket.WriteInt32 - метод

Обновлен: Ноябрь 2007

Записывает целое число в объект.

Пространство имен:  Microsoft.SmartDevice.DeviceAgentTransport
Сборка:  Microsoft.SmartDevice.DeviceAgentTransport (в Microsoft.SmartDevice.DeviceAgentTransport.dll)

Синтаксис

'Декларация
Sub WriteInt32 ( _
    in_int32 As Integer _
)
'Применение
Dim instance As IPacket
Dim in_int32 As Integer

instance.WriteInt32(in_int32)
void WriteInt32(
    int in_int32
)
void WriteInt32(
    int in_int32
)
function WriteInt32(
    in_int32 : int
)

Параметры

  • in_int32
    Тип: System.Int32
    Целое число, записываемое в пакет.

Примеры

    packet = PacketFactory.GetNewPacket()

    ' Write the version of .NET Compact Framework into the packet.
    packet.WriteString("Hello Desktop Computer")
    packet.WriteInt32(Environment.Version.Major)
    packet.WriteInt32(Environment.Version.Minor)
    packet.WriteInt32(Environment.Version.Build)
    packet.WriteInt32(Environment.Version.Revision)

    ' Pass the packet to desktop application.
    packetStream.Write(packet)

End Sub 'Main
packet = PacketFactory.GetNewPacket();

// Write the version of .NET Compact Framework into the packet.
packet.WriteString("Hello Desktop Computer");
packet.WriteInt32(Environment.Version.Major);
packet.WriteInt32(Environment.Version.Minor);
packet.WriteInt32(Environment.Version.Build);
packet.WriteInt32(Environment.Version.Revision);

// Pass the packet to desktop application.
packetStream.Write(packet);

Разрешения

См. также

Ссылки

IPacket Интерфейс

IPacket - члены

Microsoft.SmartDevice.DeviceAgentTransport - пространство имен