Click here to Skip to main content
14,693,448 members
Home » Discussions » C#
   

C#

 
QuestionI need to see if a digit from a number is odd or even in c# Pin
keeponfalling125-Aug-20 5:24
Memberkeeponfalling125-Aug-20 5:24 
AnswerRe: I need to see if a digit from a number is odd or even in c# Pin
OriginalGriff5-Aug-20 5:58
mveOriginalGriff5-Aug-20 5:58 
GeneralRe: I need to see if a digit from a number is odd or even in c# Pin
keeponfalling125-Aug-20 6:23
Memberkeeponfalling125-Aug-20 6:23 
GeneralRe: I need to see if a digit from a number is odd or even in c# Pin
OriginalGriff5-Aug-20 6:45
mveOriginalGriff5-Aug-20 6:45 
AnswerRe: I need to see if a digit from a number is odd or even in c# Pin
Gerry Schmitz5-Aug-20 6:35
mveGerry Schmitz5-Aug-20 6:35 
GeneralRe: I need to see if a digit from a number is odd or even in c# Pin
keeponfalling125-Aug-20 11:19
Memberkeeponfalling125-Aug-20 11:19 
GeneralRe: I need to see if a digit from a number is odd or even in c# Pin
Gerry Schmitz5-Aug-20 15:06
mveGerry Schmitz5-Aug-20 15:06 
QuestionHow to get ios device capacity using MDM profiling Pin
Veridic Anil4-Aug-20 23:25
MemberVeridic Anil4-Aug-20 23:25 
Based on this document from apple : https://developer.apple.com/business/documentation/MDM-Protocol-Reference.pdf

Quote:
I am trying to fetch mobile identifier by running provisioning profile on the device.
Here, I am able to get these identifiers: -


UDID
IMEI
ICCID
VERSION
PRODUCT

But this Identifier i.e. DeviceCapacity is not getting fetch.

Please find below is my code:

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
 <dict>
   <key>PayloadContent</key>
   <dict>
     <key>URL</key>
     <string>https://xyz.com/home/checkin/?udi={0}</string>
     <key>DeviceAttributes</key>
     <array>
       <string>UDID</string>
       <string>IMEI</string>
       <string>ICCID</string>
       <string>VERSION</string>
       <string>PRODUCT</string>
       <string>SERIAL</string>
       <string>MEID</string>
       <string>DEVICECAPACITY</string>

     </array>
   </dict>
   <key>PayloadOrganization</key>
   <string>cellderetail-pro-new.cellde.com</string>
   <key>PayloadDisplayName</key>
   <string>Profile Service</string>
   <key>PayloadVersion</key>
   <integer>1</integer>
   <key>PayloadUUID</key>
   <string>9CF421B3-9853-4454-BC8A-982CBD3C907C</string>
   <key>PayloadIdentifier</key>
   <string>com.cellderetailpronewprovisioning</string>
   <key>PayloadDescription</key>
   <string>This temporary profile will be used to extract your current device's identifiers.</string>
   <key>PayloadType</key>
   <string>Profile Service</string>
 </dict>
</plist>



Below is is the code for installing provisioning profile on ios device

var contentDisposition = new System.Net.Mime.ContentDisposition
                {
                    //FileName = "device-info.mobileconfig",
                    FileName = "device-information.mobileconfig",
                    Inline = false
                };
                var path = Configuration.MobileConfigPath;
                logger.LogMessage("MobileConfigPath" + path, FileLogger.MessageType.Info);
                string mobileConfigPlist = System.IO.File.ReadAllText(path);
                if (isHeadless)
                    udi = string.Format("{0}-hls-{1}-{2}-{3}-{4}-{5}-{6}", udi, storeId, StoreType, EnterpriseID,Session["TechName"],Session["Capacity"],Session["Model"]);
                var plistWithUdiUrl = mobileConfigPlist.Replace("{0}", udi);
                var bytes = getSignedContent(plistWithUdiUrl);
                logger.LogMessage("Signed Content Bytes", FileLogger.MessageType.Info);
                Response.AppendHeader("Content-Disposition", contentDisposition.ToString());
                Response.AppendHeader("Cache-Control", "public, no-store, max-age=0");
                return File(bytes, "application/x-apple-aspen-config");



As kind of help / suggestion are welcomed
AnswerRe: How to get ios device capacity using MDM profiling Pin
Gerry Schmitz5-Aug-20 6:58
mveGerry Schmitz5-Aug-20 6:58 
QuestionDataBase in User Control Pin
Member 147923934-Aug-20 5:15
MemberMember 147923934-Aug-20 5:15 
AnswerRe: DataBase in User Control Pin
OriginalGriff4-Aug-20 5:32
mveOriginalGriff4-Aug-20 5:32 
GeneralRe: DataBase in User Control Pin
Gerry Schmitz4-Aug-20 7:12
mveGerry Schmitz4-Aug-20 7:12 
GeneralRe: DataBase in User Control Pin
OriginalGriff4-Aug-20 7:26
mveOriginalGriff4-Aug-20 7:26 
QuestionHow can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w31-Jul-20 3:38
Memberarnold_w31-Jul-20 3:38 
AnswerRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Eddy Vluggen31-Jul-20 3:53
professionalEddy Vluggen31-Jul-20 3:53 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w31-Jul-20 5:03
Memberarnold_w31-Jul-20 5:03 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Richard MacCutchan31-Jul-20 5:49
mveRichard MacCutchan31-Jul-20 5:49 
AnswerRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w31-Jul-20 12:03
Memberarnold_w31-Jul-20 12:03 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Gerry Schmitz31-Jul-20 13:41
mveGerry Schmitz31-Jul-20 13:41 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Richard Andrew x6431-Jul-20 17:22
professionalRichard Andrew x6431-Jul-20 17:22 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w1-Aug-20 0:09
Memberarnold_w1-Aug-20 0:09 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w1-Aug-20 0:58
Memberarnold_w1-Aug-20 0:58 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Richard Andrew x641-Aug-20 2:44
professionalRichard Andrew x641-Aug-20 2:44 
GeneralRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
arnold_w1-Aug-20 2:55
Memberarnold_w1-Aug-20 2:55 
AnswerRe: How can I get handle (IntPtr) to a "sub"-form in another application? Pin
Richard Andrew x641-Aug-20 2:47
professionalRichard Andrew x641-Aug-20 2:47 

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.