DNS entry missing - About xda-developers.com

When I tried to register to this forum, I used my email from my own server. But your confirmation mail gets rejected with:
Code:
relay=50.23.193.227-static.reverse.softlayer.com [50.23.193.227], reject=451 4.1.8 Domain of sender address [email protected] does not resolve
I've tried a "dig xda-developers.com" but there seems to be no "A-record" nor "MX-record" for this domain.
Now I used a GMX-email and your confirmation goes directly into spam-folder.
I checked your nameservers at http://www.whatsmydns.net/#NS/xda-developers.com
And it seems, the german server in Berlin also don't know your IP, but every other servers do know it.
I think it is because your NS-entry points to the sub-domain of xda-developers.com, so the ns1.xda-developers.com cannot been resolved, since my nameserver don't know who to ask for the IP of ns1.xda-developers.com ;-)
For sure, ns1.xda-developers.com knows the IP of ns1.xda-developers.com and also of xda-developers.com, but nobody else knows this IP.
This is the +trace of dig xda-developers.com:
Code:
[email protected]:/var/log# dig xda-developers.com +trace
; <<>> DiG 9.7.3 <<>> xda-developers.com +trace
;; global options: +cmd
. 517653 IN NS a.root-servers.net.
. 517653 IN NS g.root-servers.net.
. 517653 IN NS b.root-servers.net.
. 517653 IN NS h.root-servers.net.
. 517653 IN NS j.root-servers.net.
. 517653 IN NS e.root-servers.net.
. 517653 IN NS c.root-servers.net.
. 517653 IN NS m.root-servers.net.
. 517653 IN NS l.root-servers.net.
. 517653 IN NS k.root-servers.net.
. 517653 IN NS f.root-servers.net.
. 517653 IN NS i.root-servers.net.
. 517653 IN NS d.root-servers.net.
;; Received 512 bytes from 127.0.0.1#53(127.0.0.1) in 0 ms
com. 172800 IN NS a.gtld-servers.net.
com. 172800 IN NS m.gtld-servers.net.
com. 172800 IN NS d.gtld-servers.net.
com. 172800 IN NS k.gtld-servers.net.
com. 172800 IN NS l.gtld-servers.net.
com. 172800 IN NS i.gtld-servers.net.
com. 172800 IN NS b.gtld-servers.net.
com. 172800 IN NS c.gtld-servers.net.
com. 172800 IN NS g.gtld-servers.net.
com. 172800 IN NS h.gtld-servers.net.
com. 172800 IN NS f.gtld-servers.net.
com. 172800 IN NS j.gtld-servers.net.
com. 172800 IN NS e.gtld-servers.net.
;; Received 496 bytes from 192.228.79.201#53(b.root-servers.net) in 170 ms
xda-developers.com. 172800 IN NS ns2.xda-developers.com.
xda-developers.com. 172800 IN NS ns1.xda-developers.com.
xda-developers.com. 172800 IN NS ns3.xda-developers.com.
;; Received 138 bytes from 192.26.92.30#53(c.gtld-servers.net) in 104 ms
;; connection timed out; no servers could be reached
The other servers may know your IP maybe because some time in the past your NS were somewhere else hosted, so the IPs were constantly cached by the other nameservers since your site is really heavy used.

Related

Probelms with event handling and threads in CF3.5 on VB

HI!
I have a big problem with event handling in VS 2008. I'm writing a GPS program which determine the coordinates, attitude, speed etc. This is a part of a compass program. I'm using the Microsoft's GPS Intermediate Driver. I also use thread to the GPS reading from serial port to not interferre with the UI and the compass because the serial port reading is very slow and stops the compass' spinning for a second at every reading. I was ran through tons of forums and examples about the threads and event handling, but whenever I start the program and the event rises I get this error message:
NotSupportedException
Microsoft.AGL.Common.MISC.HandleArr(PAL_ERROR ar)
System.Windows.Forms.Control.get_Text()
System.Windows.Forms.Control.set_Text(String value)
O2Compass_VB.Form1._Lambda$__1(Object a0, LocationChangeEventArgs a1)
Microsoft.WindowsMobile.Samples.Location.GPS.WaitForGpsEvents()
The code is the next:
Code:
Imports Microsoft.WindowsMobile.Samples.Location
Imports System.Threading
Dim LatRef, LonRef As String
Dim WithEvents GPS As New Gps
'Start GPS readings
GPS.Open()
'Start thread
Dim GPSThread = New Thread(AddressOf GPSDataWriteOut)
GPSThread.Start()
Private Sub GPSDataWriteOut() Handles GPS.LocationChanged
If GPS.GetPosition.Latitude < 0 Then LatRef = "S" Else LatRef = "N"
If GPS.GetPosition.Longitude < 0 Then LonRef = "W" Else LonRef = "E"
If GPS.GetPosition.LatitudeValid Then LatTXT.Text = "Lattitude: " + GPS.GetPosition.Latitude.ToString("#0.0000000") + " " + LatRef
If GPS.GetPosition.LongitudeValid Then LongTXT.Text = "Longitude: " + GPS.GetPosition.Longitude.ToString("#0.0000000") + " " + LonRef
If GPS.GetPosition.SeaLevelAltitudeValid Then AltTXT.Text = "Altitude: " + GPS.GetPosition.SeaLevelAltitude.ToString + " m"
If GPS.GetPosition.SpeedValid Then SpeedTXT.Text = "Speed: " + GPS.GetPosition.Speed.ToString
If (GPS.GetPosition.SatelliteCountValid) And (GPS.GetPosition.SatellitesInViewCountValid) Then SatsTXT.Text = "Sattelites: " + GPS.GetPosition.SatelliteCount.ToString + " / " + GPS.GetPosition.SatellitesInViewCount.ToString
End Sub
And all of this works on the device emulator, but on the phone it's crash. When I'm put the writeouts in a timer it works but then I can't use thread.
Anyone can help me to fix this error? I though the code was right, but always came the same error. What am I doing wrong?
I managed to solve the problem.
The event handling is a different thread, no need to create one to it. And because it's a new working thread, it can't update the label's text of the main thread. So I just pass through the received datas to a variable in the main thread and write it out with a timer if the datas received.

[Q] Vb.net Json SecurityException Problem

I am currently trying to port my Grooveshark(tm) Applications to WP7
currently I am facing a problem that I do not understand:
Code:
Dim jss As New DataContractJsonSerializer(SendObject.GetType())
Dim serialisedRequestContentBuilder As New StringBuilder()
Dim fWP7Stream As New MemoryStream
jss.WriteObject(fWP7Stream, SendObject)
I get following error on " jss.WriteObject(fWP7Stream, SendObject)" :
Code:
System.Security.SecurityException was unhandled
Message=SecurityException
StackTrace:
at System.Runtime.Serialization.DataContract.DataContractCriticalHelper.CreateDataContract(Int32 id, RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.DataContract.DataContractCriticalHelper.GetDataContractSkipValidation(Int32 id, RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.DataContract.GetDataContractSkipValidation(Int32 id, RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.DataContract.GetDataContract(RuntimeTypeHandle typeHandle, Type type, SerializationMode mode)
at System.Runtime.Serialization.DataContract.GetDataContract(RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.DataContract.GetDataContract(Type type, Assembly serializerAssembly)
at System.Runtime.Serialization.Json.DataContractJsonSerializer.get_RootContract()
at System.Runtime.Serialization.Json.DataContractJsonSerializer.WriteObject(Stream stream, Object graph)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.WriteRequestContent(Object SendObject)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.MakeRequest()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.GetCommunicationToken()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.Connect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.CheckConnect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.SearchArtist(String Search, Int32 Limit)
at SciLor_s_GrooveMobile_WP7_C.MainPage.<btnSearch_Click>b__0()
InnerException:
The object that should be serialized is:
Code:
Public Class ConnectGroovesharkRequest
Public header As ConnectGroovesharkHeader
Public parameters As GetCommunicationTokenParams
Public method As String
Sub New(ByVal myHeader As ConnectGroovesharkHeader, ByVal myParameter As GetCommunicationTokenParams, ByVal myMethod As String)
header = myHeader
parameters = myParameter
method = myMethod
End Sub
End Class
The subclasses are:
Code:
Public Class ConnectGroovesharkHeader
Public uuid As String
Public clientRevision As String
Public session As String
Public client As String
Sub New(ByVal myUuid As String, ByVal mySession As String, ByVal myClient As String, ByVal myClientRevision As String)
uuid = myUuid
clientRevision = myClientRevision
session = mySession
client = myClient
End Sub
End Class
Public Class GetCommunicationTokenParams
Public secretKey As String
End Class
End Class
Has anybody a clue where this error comes from?
According the MSDN docs, sometimes this exception is thrown when really a MethodAccessException should be thrown instead. Try making sure all properties which need to be mapped from the JSON are public.
I always use JSON.NET in my windows phone apps anyway as it give me more control over deserialization and the API is a lot cleaner:
http://james.newtonking.com/pages/json-net.aspx
Thank you for this hint, I am already using it on my Windows Mobile apps in an older version. (Everything worked with that old version very fine, the api now is the same on wp7)
There is now a different error:
Code:
Newtonsoft.Json.JsonSerializationException was unhandled
Message=Error getting value from 'parameters' on 'SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2+ConnectGroovesharkRequest[SciLorsGroovesharkAPI.Groove.Functions.CommunicationToken+GetCommunicationTokenParams,SciLorsGroovesharkAPI.Groove.Functions.CommunicationToken+GetCommunicationTokenResponse]'.
StackTrace:
at Newtonsoft.Json.Serialization.ReflectionValueProvider.GetValue(Object target)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.SerializeObject(JsonWriter writer, Object value, JsonObjectContract contract, JsonProperty member, JsonContract collectionValueContract)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.SerializeValue(JsonWriter writer, Object value, JsonContract valueContract, JsonProperty member, JsonContract collectionValueContract)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.Serialize(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.SerializeInternal(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.Serialize(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.Serialize(TextWriter textWriter, Object value)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.WriteRequestContent(Object SendObject)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.MakeRequest()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.GetCommunicationToken()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.Connect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.CheckConnect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.SearchArtist(String Search, Int32 Limit)
at SciLor_s_GrooveMobile_WP7_C.MainPage.<btnSearch_Click>b__0()
InnerException: System.FieldAccessException
Message=SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2+ConnectGroovesharkRequest.parameters
StackTrace:
at System.Reflection.RuntimeFieldInfo.GetValue(Object obj)
at Newtonsoft.Json.Utilities.ReflectionUtils.GetMemberValue(MemberInfo member, Object target)
at Newtonsoft.Json.Serialization.ReflectionValueProvider.GetValue(Object target)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.SerializeObject(JsonWriter writer, Object value, JsonObjectContract contract, JsonProperty member, JsonContract collectionValueContract)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.SerializeValue(JsonWriter writer, Object value, JsonContract valueContract, JsonProperty member, JsonContract collectionValueContract)
at Newtonsoft.Json.Serialization.JsonSerializerInternalWriter.Serialize(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.SerializeInternal(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.Serialize(JsonWriter jsonWriter, Object value)
at Newtonsoft.Json.JsonSerializer.Serialize(TextWriter textWriter, Object value)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.WriteRequestContent(Object SendObject)
at SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2.MakeRequest()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.GetCommunicationToken()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.Connect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.CheckConnect()
at SciLorsGroovesharkAPI.Groove.GroovesharkClient.SearchArtist(String Search, Int32 Limit)
at SciLor_s_GrooveMobile_WP7_C.MainPage.<btnSearch_Click>b__0()
InnerException:
That appears to be the same issue as you were having with the data contract serializer. My VB isn't fantastic, but I would make all those public variables properties with Get/Set accessors and again, make sure all classes and properties are marked public - at least until you get to the bottom of the issue
Sent from my 7 Pro T7576 using Board Express
I really cannot change them to setters and getters, that would lead into recreating the whole project .
But I saw that it seems to work with properties :-/. Don't you know any flag for the Json.net to allow it for the public variables?!
The weird thing is, that there is no problem to serialize into an object only having public variables and no properties. But when tring the other way round there is this weird error
scilor said:
I really cannot change them to setters and getters, that would lead into recreating the whole project .
But I saw that it seems to work with properties :-/. Don't you know any flag for the Json.net to allow it for the public variables?!
The weird thing is, that there is no problem to serialize into an object only having public variables and no properties. But when tring the other way round there is this weird error
Click to expand...
Click to collapse
Strange! You could try the JsonSerializerSettings member handling classes:
http://james.newtonking.com/project...nSerializerSettings_MissingMemberHandling.htm
But I've never exposed public variables directly using this library, only ever properties.
With some clever regular expressions within the Find & Replace dialog in VS2010, you could replace those public properties without much issue... Does it work if you only replace the "parameters" object's parent class variables with properties?
I found the problems, its not the json.net libary its silverlight... And this error seems to come also on properties I just found out .
I get following error:
Code:
[System.FieldAccessException] = {"SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2+ConnectGroovesharkRequest.method"}
On the line
Code:
((FieldInfo)member).GetValue(target);
This error should only occour on private variables... I do not understand this.
Seems to be a feature by wp7...
(Really thank you for trying to help me!)
scilor said:
I found the problems, its not the json.net libary its silverlight... And this error seems to come also on properties I just found out .
I get following error:
Code:
[System.FieldAccessException] = {"SciLorsGroovesharkAPI.Groove.GroovesharkRequestBuilder`2+ConnectGroovesharkRequest.method"}
On the line
Code:
((FieldInfo)member).GetValue(target);
This error should only occour on private variables... I do not understand this.
Seems to be a feature by wp7...
(Really thank you for trying to help me!)
Click to expand...
Click to collapse
Just looking down through your StackTrace. Is the call in a separate assembly or anything? Or are you maybe initializing the object in one thread and trying to serialize it in another?
It clearly thinks that it doesn't have permission to read that object somehow. Maybe make the object static (Shared in VB?) to see if that gets rid of the error - if so, you know it's an issue with passing the instance of that object.
I worked on a Grooveshark client for WP7 myself (it's in C#), maybe it can be of some use:
http://sharkstream.unfuddle.com/svn/sharkstream_main/
(This also uses the JSON.NET library)
I am knowing c# and vb.net ^^ so there is any need of jumping to vb.net.
Just my api is in vb.net, the rest is in c#.
I have got an Grooveshark(tm).com api in a Vb.net project and the UI for WP7 is in c#. Maybe thats is the problem :-/. I do not know...
The website asks for a login
EDIT:
Got it, one of the classes was marked as "Friend" -.-

[Q][Solved] Masking combobox items with text [VB.Net CF]

So basically this is what i need:
say i have a combo box that has 2 items, 0 and 1. When i say combobox1.SelectedItem and the number 1 is selected, it is then used within the program.
But what i want to do is have a combobox that displays say, on and off, but when on is selected a 1 is passed to the program.
Been googling this on and off for 2 weeks or so and I'm not able to find the answer and i know it can be done.
Thoughts and suggestions, as ever, are appreciated.
Use the SelectedIndex property of the ComboBox. It will return as an integer, a zero based index of the item selected, or -1 if no item is selected.
In your ComboBox, if the first item is 'Off' and the second, 'On', then the SelectedIndex property will return 0 and 1 respectively.
P.S. SelectedItem returns whatever is in the selected entry of the ComboBox.
stephj said:
Use the SelectedIndex property of the ComboBox. It will return a zero based index of the item selected, or -1 if no item is selected.
In your ComboBox, if the first item is 'Off' and the second, 'On', then the SelectedIndex property will return 0 and 1 respectively.
P.S. SelectedItem returns whatever is in the selected entry of the ComboBox.
Click to expand...
Click to collapse
OK that sounds pretty easy. I'm surprised i didn't find that in my searchs. Now lets up the anty. In EXCT2 i have a combobox that has the following items.
Code:
0
512
1024
2048
5120
10240
20480
102400
-2
-1
These are values used by the exchange (sync) configuration OMA service provider to configure the truncation point of html email messages. 512 is 0.5KB and it moves up to 100KB. Then -2 is text but no pictures and -1 is for the entire message. So if i wanted to say 0.5KB as the item how do i tell the program to use the value 512?
Hmmmm...... Trickier, but not impossible.....
Try this.
The secret is to connect the ComboBox to a DataSource, and let it get its DisplayMember and ValueMember properties from there.
You have to write a class to load and present the values then load them into an ArrayList first.
You then point the DataSource property of the ComboBox at the ArrayList, and let it get on with it.
Code:
Imports System
Imports System.Windows.Forms
Imports System.Collections
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim TruncVals As New ArrayList()
TruncVals.Add(New TruncVal("None", 0))
TruncVals.Add(New TruncVal("0.5Kb", 512))
TruncVals.Add(New TruncVal("1Kb", 1024))
TruncVals.Add(New TruncVal("2Kb", 2048))
TruncVals.Add(New TruncVal("5Kb", 5120))
TruncVals.Add(New TruncVal("10Kb", 10240))
TruncVals.Add(New TruncVal("20Kb", 20480))
TruncVals.Add(New TruncVal("100Kb", 102400))
TruncVals.Add(New TruncVal("Text no pictures", -2))
TruncVals.Add(New TruncVal("Entire Message", -1))
ComboBox1.DataSource = TruncVals
ComboBox1.DisplayMember = "TruncStr"
ComboBox1.ValueMember = "TruncInt"
ComboBox1.SelectedIndex = -1
TextBox1.Text = ""
End Sub
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
If ComboBox1.SelectedIndex <> -1 Then
TextBox1.Text = ComboBox1.SelectedValue.ToString()
End If
End Sub
End Class
Public Class TruncVal
Private MyTruncStr As String
Private MyTruncInt As Integer
Public Sub New(ByVal StrVal As String, ByVal IntVal As Integer)
Me.MyTruncStr = StrVal
Me.MyTruncInt = IntVal
End Sub
Public ReadOnly Property TruncStr() As String
Get
Return MyTruncStr
End Get
End Property
Public ReadOnly Property TruncInt() As Integer
Get
Return MyTruncInt
End Get
End Property
End Class

[Q] Determining if a Sub needs to be run based on the object that called it [VB.Net]

Ok i know the title is not very good but this is a hard one to describe so briefly.
Basically i have a bunch of sub procedures that look a lot like this
Code:
[SIZE=2][COLOR=#0000ff]
[SIZE=2][COLOR=#0000ff]Public[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sender [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] System.Object, [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] e [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] System.EventArgs) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Handles[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBButton.Click[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]On[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Error[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Resume[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Next[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBUsrnme [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookUserName"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBpass [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookPassword"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBsecret [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSecret"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBUsrID [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Integer[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookUserID"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBsession [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSession"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBToken [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookToken"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBAccount [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookAccount"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBSavePass [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSavePassword"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] DirPath [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = SaveLocForm.Label28.Text[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] IO.StreamWriter = IO.File.CreateText(DirPath + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"\facebook.reg"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000]'Format and then write the reg file to disk[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]sw.WriteLine(RegHead)[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"[HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager]"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookUserName""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBUsrnme.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookPassword""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBpass.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSecret""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBsecret.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookUserID""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBUsrID.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSession""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBsession.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookToken""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBToken.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookAccount""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBAccount.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSavePassword""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBSavePass.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.Flush()[/SIZE]
[SIZE=2]sw.Close()[/SIZE]
[SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000]'Check that the file wrote successfully (this needs work becuase it will always report "operation successful" once the file has been written once[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] File.Exists(DirPath + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"\facebook.reg"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] fsi [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FileSystemInfo = [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]New[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FileInfo(DirPath + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"\facebook.reg"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] (DateAndTime.Now - fsi.LastWriteTime) < [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]New[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] TimeSpan(0, 0, 5) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]OpComplete()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Else[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]OpFailed()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE]
[/COLOR][/SIZE]
Now the bit i'm interested in is the final part because i have another part of my program that calls all the sub procedures like this
Code:
[SIZE=2][COLOR=#0000ff]
[SIZE=2][COLOR=#0000ff]Private[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] MenuItem2_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sender [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] System.Object, [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] e [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] System.EventArgs) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Handles[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] MenuItem2.Click[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]On[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Error[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Resume[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Next[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]ExchangeForm.exchangeSet_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]Soundbcklght.Backlghtset_click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]Identities.BTIdent_click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]Identities.PhoneIdent_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]Soundbcklght.bak_vol_set_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]Soundbcklght.RingSet_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]GPSForm.AGPSButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]GPSForm.LocServ_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]GPSForm.QGPS_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]ClockAlarmForm.TimeAutoUp_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]WiFiForm.WifiButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]VPNForm.VPNButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]AudioManager.AudioPathBut_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]SocialNetworks.FBButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]SocialNetworks.TwitButton_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]AudioManager.AlbumIgnore_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]HotmailForm.HotmailBut_Click([/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]MessageBox.Show([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"All Operations have run. All succesful exports can be found in "[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + SaveLocForm.Label28.Text)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE]
[/COLOR][/SIZE]
As you can see what happens when MenuItem2 is clicked is it runs through all of the sub procedures and at the end of each procedure there is a check to see if the file it is supposed to write was done successfully and they each then create a mesage box saying if they were successful or not. Then, once MenuItem2 has completed it creates a message box saying that all operations have run and tells you where they have been saved. So when you click MenuItem2 it basically creates 18 messageboxes that either say "operation complete" or "operation failed" followed by MenuItem2's own message box
What i want to happen (well actually my testers want it) is when you run say FBButton_click on it's own it creates the opcomplete or opfailed message boxes but when it is run as part of MenuItem2 it skips that part of the code.
So, i've moved the file write check out of a test procedure and into a module. Added a global variable so now the procedure looks like this
Code:
[SIZE=2][COLOR=#0000ff]
[SIZE=2][COLOR=#0000ff]Public[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] FBButton_Click([/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] sender [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] System.Object, [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]ByVal[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] e [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] System.EventArgs) [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Handles[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] FBButton.Click[/COLOR][/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]On[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Error[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Resume[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Next[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBUsrnme [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookUserName"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBpass [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookPassword"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBsecret [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSecret"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBUsrID [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Integer[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookUserID"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBsession [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSession"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBToken [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookToken"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBAccount [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookAccount"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FBSavePass [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = Registry.GetValue([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"FaceBookSavePassword"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2], 0)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] DirPath [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = SaveLocForm.Label28.Text[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] IO.StreamWriter = IO.File.CreateText(DirPath + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"\facebook.reg"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000]'Format and then write the reg file to disk[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]sw.WriteLine(RegHead)[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"[HKEY_LOCAL_MACHINE\Software\HTC\HTCAccountManager]"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookUserName""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBUsrnme.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookPassword""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBpass.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSecret""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBsecret.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookUserID""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBUsrID.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSession""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBsession.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookToken""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBToken.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookAccount""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBAccount.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.WriteLine([/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"""FaceBookSavePassword""="""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] + FBSavePass.ToString + [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]""""[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])[/SIZE]
[SIZE=2]sw.Flush()[/SIZE]
[SIZE=2]sw.Close()[/SIZE]
[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000]'Check that the file wrote successfully (this needs work becuase it will always report "operation successful" once the file has been written once[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]ModGlobal.dirpath1 = sw.ToString[/SIZE]
[SIZE=2]ModGlobal.FileCheck()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE]
[/COLOR][/SIZE]
and the module looks like this
Code:
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Public[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] dirpath1 [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE]
[SIZE=2][COLOR=#0000ff]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Public[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FileCheck()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] File.Exists(dirpath1) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] fsi [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FileSystemInfo = [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]New[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] FileInfo(dirpath1)[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] (DateAndTime.Now - fsi.LastWriteTime) < [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]New[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] TimeSpan(0, 0, 6) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]ModGlobal.OpComplete()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Else[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2]ModGlobal.OpFailed()[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE]
[/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE]
[/COLOR][/SIZE]
And this is where i get stuck. I have no idea how to write a check in to the test sub procedure that asks where it was called from and is then able to determine whether or not to call the FileCheck sub.
If you have any ideas i would be most greatful and i'm also sorry for the long post but it is a pretty complicted question.
The 'sender' parameter of an event handler points back to the object that originally caused this event handler to be triggered.
Create one Subroutine to handle both click events.
Use the Name property of the GetType() method of "sender", to decide which object invoked the event handler.
eg.
Code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click, MenuItem2.Click
If sender.GetType().Name = "Button" Then
Label1.Text = "Button pressed."
End If
If sender.GetType().Name = "MenuItem" Then
Label1.Text = "Menu Clicked."
End If
End Sub
End Class
If you're going to do this in a separate subroutine from the click events, then you will have to pass it 'sender' as an argument, for your subroutine to decide, which of the event handlers called it.
Note that the above only identifies the type of the object that invoked the handler. If you want to find out exactly which of several objects of the same type invoked the handler then you need to create a variable of that type, and set it to the value of sender to allow you to access its properties.
Code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click, MenuItem2.Click
If sender.GetType().Name = "Button" Then
Dim Source As Button
Source = sender
Label1.Text = "Button [" + Source.Text + "] pressed."
End If
If sender.GetType().Name = "MenuItem" Then
Dim Source As MenuItem
Source = sender
Label1.Text = "MenuItem [" + Source.Text + "] pressed."
End If
End Sub
End Class
Results in :
Code:
"Button [Go] pressed."
or
"MenuItem [Menu Go] pressed."
Ok but what if "menuitem" is on a different form to "button"? I think i understand the concept you discuss in your post but i'm having trouble implementing it because (and this is a guess) Menuitem2 lives in form1 and FbButton has it's own form. If i try referencing menuitem2 in FbButton's handlers it kicks back an error that i can resolve. To give you an idea this is kinda what i'm trying to achieve.
Code:
[SIZE=2][COLOR=#0000ff]Public[SIZE=2][SIZE=2]Sub[/SIZE][/SIZE][SIZE=2] FBButton_Click([/SIZE][SIZE=2][SIZE=2]ByVal[/SIZE][/SIZE][SIZE=2] sender [/SIZE][SIZE=2][SIZE=2]As[/SIZE][/SIZE][SIZE=2] System.Object, [/SIZE][SIZE=2][SIZE=2]ByVal[/SIZE][/SIZE][SIZE=2] e [/SIZE][SIZE=2][SIZE=2]As[/SIZE][/SIZE][SIZE=2] System.EventArgs) [/SIZE][SIZE=2][SIZE=2]Handles[/SIZE][/SIZE][SIZE=2] FBButton.Click, form1.menuitem2.click[/SIZE][/COLOR]
[COLOR=#0000ff][SIZE=2][SIZE=2]On [/SIZE][/SIZE][SIZE=2][SIZE=2]Error GoTo errorhandler[/SIZE][/SIZE][/COLOR][/SIZE]
[SIZE=2]
[COLOR=#0000ff][COLOR=black]-- SNIP --[/COLOR]
[/COLOR][/SIZE]
[SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000]'Check that the file wrote successfully (this needs work becuase it will always report "operation successful" once the file has been written once[/COLOR][/SIZE]
[/COLOR][/SIZE]
[SIZE=2][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] sender.GetType().Name = Form1.MenuItem2 [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]GoTo[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] endsub[/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Else[/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] File.Exists(dirpath1) [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then[/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2]FileOWForm.ShowDialog()[/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Else[/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2]ModGlobal.FileCheck()[/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][/SIZE]
[SIZE=2][SIZE=2][COLOR=#008000][SIZE=2][COLOR=#008000][COLOR=#0000ff]End[/COLOR][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE]
[SIZE=2]errorhandler:[/SIZE]
[SIZE=2]ModGlobal.OpFailed()[/SIZE]
[SIZE=2]endsub:[/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][/COLOR][/SIZE]
[/SIZE]
I know that's wrong but i'm not sure how to make it work. Oh and FileOWForm basically asks if you want to overwrite the existing file, just so you know.
In that case on Form2 pass it straight through to the receiving event on Form1
Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Form1.Button1_Click(sender, e)
End Sub
The attached project is an example.
stephj said:
In that case on Form2 pass it straight through to the receiving event on Form1
Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Form1.Button1_Click(sender, e)
End Sub
The attached project is an example.
Click to expand...
Click to collapse
Cool thanks. I'll have a look at this later coz it's beer o'clock shortly
so i tied up the code in my program a little and had a play with what you came up with and i got this:
Code:
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]
If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sender.GetType.Name = [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"Button"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then
[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]ModGlobal.FileCheck()
[/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If
[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] sender.GetType.Name = [/SIZE][SIZE=2][COLOR=#a31515][SIZE=2][COLOR=#a31515]"MenuItem"[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then
[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Exit[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Sub
[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If
[/COLOR][/SIZE][/COLOR][/SIZE]
I haven't tested it yet coz i have other stuff to do but i was wondering if you think i got the basic idea?
Thanks again for being so helpful, steph
It will work, but as long as you are aware of the following proviso, it should be fine.
The code is determining its action solely by the type of the object that triggered the event. You may have to bear this in mind if you want to add a load more functionality, later.
The usual use for this sort of thing, is if you have a bunch of similar objects but want to write just one event handler to process events from all of them - a group of similar buttons, say. By using the trick in the middle code window in post #5, you can find out exactly which button of the group was clicked to invoke the handler, and run whatever code is required for that button. It prevents having to write the code for every button/event, especially if they have a large amount of similar code/shared functionality.
Good Luck! stephj.
Well i did some testing and i can't make the code i posted work (why am i not surprised) and i'm not sure i understand your last post. I've read it 5 times and it just doesn't seem to make sense. Is it me being retarded or is there a few typos in it?
What I meant, in a nutshell was this.
Nine buttons, only one event handler.
Code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles _
Button1.Click, _
Button2.Click, _
Button3.Click, _
Button4.Click, _
Button5.Click, _
Button6.Click, _
Button7.Click, _
Button8.Click, _
Button9.Click
Dim SendingButton As Button
SendingButton = sender
Label1.Text = "Button " + SendingButton.Text + " Pressed"
End Sub
End Class
I give up!
Right, well i tried the method you posted above and Visual studio won't let me do it because there is no matching WithEvents variable for the second handle (probably because it is on a different form) and the method i posted in post 6 generates a nullreference exception at the first line.
I really can't figure out what i'm doing wrong, it's starting to irritate me and i've lost my patience for it.
Fancy volunteering some more of that brain of yours, Steph?
GetType is a method not a property.
Code:
If sender.GetType().Name = "Button"Then
ModGlobal.FileCheck()
EndIf
If sender.GetType().Name = "MenuItem"Then
ExitSub
EndIf
The included example below works. Here's the code for the two forms. The only deliberate change is to declare Form1's Button2_Click() as Public, to enable Form2 to be able to call it.
Code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Form2.Show()
End Sub
Public Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Dim SenderButton As Button
SenderButton = sender
Label1.Text = "Button : " + SenderButton.Text + " clicked"
End Sub
End Class
Public Class Form2
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Form1.Show()
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Form1.Button2_Click(sender, e)
End Sub
End Class
I got it. I only saw the first half of your post when i was checking my mail this morning so i made the chagnge to gettype() and that got the first part working (calling it from it's own button).
After then calling the code from a menuitem on a different form and getting a failure it was revealed i made a noobie error. When i was calling the buttons function i was defining the objects like so
Code:
[SIZE=2]
Soundbcklght.Backlghtset_Click([COLOR=blue]Nothing[/COLOR], [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])
[/SIZE]
instead of like this
Code:
[SIZE=2]
Soundbcklght.Backlghtset_Click(MenuItem2, [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Nothing[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2])
[/SIZE]
Now everything works fine. Thank you very much for helping once again, steph. I really can't express how greateful i am.

[Q] New contacts being deleted, why

I've now attempted to add the same contact about 5 times over the last few days, but have had no luck what so ever.
- Add the contact fine (To Google account)
- Contact is now added to my phone.
- Do a sync.
- Contact is deleted from my phone.
Anyone know what is going on here?
Is there some Google setting some where that stops you being able to add contacts or something?
Any advice welcome
Phone: HTC One X
Android: 4.2.2
Sense: 5.0
Software number 4.18.771.4
-=nezero=- said:
I've now attempted to add the same contact about 5 times over the last few days, but have had no luck what so ever.
- Add the contact fine (To Google account)
- Contact is now added to my phone.
- Do a sync.
- Contact is deleted from my phone.
Anyone know what is going on here?
Is there some Google setting some where that stops you being able to add contacts or something?
Any advice welcome
Phone: HTC One X
Android: 4.2.2
Sense: 5.0
Software number 4.18.771.4
Click to expand...
Click to collapse
save contact to phone memory or sim..!!!
Poojan Patel said:
save contact to phone memory or sim..!!!
Click to expand...
Click to collapse
That's no solution ! Should be possible to save them to google, i know i can and they are not deleted from my contacts. It could indeed be some setting but i don't know where.
Mr Hofs said:
That's no solution ! Should be possible to save them to google, i know i can and they are not deleted from my contacts. It could indeed be some setting but i don't know where.
Click to expand...
Click to collapse
Looks to me like its a Google Issue - I just have no idea where to report it to get it fixed (Google support is terrible unless you are using a paid for service!)
I tried getting a logcat of it happening to see if there is anything i can spot going wrong.
Code:
D/PowerManagerService( 508): acquireWakeLock(41c3a408): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1, pid=508, uid=1000
D/PowerManagerService( 508): acquireWakeLock(41ed3f78): PARTIAL_WAKE_LOCK , tag=*sync*_com.android.contacts_Account {name=*************, type=com.google}, flags=0x1, pid=508, uid=1000
D/PowerManagerService( 508): releaseWakeLock(4181b5d0): PARTIAL_WAKE_LOCK , tag=SyncManagerHandleSyncAlarm, flags=0x1
D/PowerManagerService( 508): releaseWakeLock(41c3a408): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1
D/PowerManagerService( 508): acquireWakeLock(4252f8f0): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1, pid=508, uid=1000
D/PowerManagerService( 508): releaseWakeLock(41ed3f78): PARTIAL_WAKE_LOCK , tag=*sync*_com.android.contacts_Account {name=*************, type=com.google}, flags=0x1
D/PowerManagerService( 508): releaseWakeLock(4252f8f0): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1
D/PowerManagerService( 508): acquireWakeLock(41ec0eb8): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1, pid=508, uid=1000
D/PowerManagerService( 508): releaseWakeLock(41ec0eb8): PARTIAL_WAKE_LOCK , tag=SyncLoopWakeLock, flags=0x1
....
D/ContactsSyncAdapter( 9855): ForbiddenException, ignoring rest of feed
D/ContactsSyncAdapter( 9855): com.google.wireless.gdata2.client.ForbiddenException: Could not fetch feed https://www.google.com/m8/feeds/groups/[email protected]/base2_property-android?showdeleted=true&orderby=lastmodified&updated-min=2013-08-28T07%3A57%3A30.603Z&sortorder=ascending&max-results=500&requirealldeleted=true com.google.wireless.gdata2.client.HttpException: Received 403 status code: <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8">
D/ContactsSyncAdapter( 9855): <title>Error
D/ContactsSyncAdapter( 9855): 403
D/ContactsSyncAdapter( 9855): (Forbidden)!!1</title>
D/ContactsSyncAdapter( 9855): <style type="text/css">
D/ContactsSyncAdapter( 9855): *{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKsAAADVCAMAAAAfHvCaAAAAGFBMVEVYn%2BH%2F%2F%2F%2Bex%2B3U5vd7s%2Bfq8%2Fs0itq72PMLUPvtAAASvklEQVR4AbXBC0JqCQxEwT5Jd7L%2FHc8FdR4g%2BEGtEr8u%2FBHxu7otdzd%2FQPyqlmRp1Pw%2B8aukDfRa1fw28ZtWy4sa89vEb7LCi0zx28RvqgkvouW3id%2FU8pbtWmv5beJXRWNrRmp%2BnfhlHXZm%2BQPi95Vk%2FoD4fZbMHxC%2FryTzB8Tva435A%2BL3rcb8AfH7VjJ%2FQPy%2BHYk%2FIH5facwfEL8iaZcrnKyn%2BAPi57K2VL2WF1hJ%2FAHxQ2tJrg6HteXVjPkD4ge6V3J1%2BF97zhx%2BnXhWb8nacKXlnYPErxNPyfqw4ZYKVuUZdfhd4hmxunY73NICgfWMOvwm8ZQ1pMvlDZdaCic98kjV4beIp8ScpLvsSvhflzqQmqVLB281v0E8pc2bdNne8EayNTPNSbt02PBj4intcKltb%2FNibY%2BLf9aSO%2FyMeMo6XMva3g0vwrWsxvyMeEoc3knZ2g53ZaXa8DzxlHa4J23Jae5aycXTxFPa4WRdXAtdsivckZXG4TniKWtOSlre6y7LG651Wxq5OzxDPGUVIKNwX6ekCv%2B0ddglVPMM8ZQ10FJ4LGVvOEuXRl7OqnmGeEor4Ck%2BtnI1ZEvjDa%2FcPEM8ZQVY4RO9VqUlN%2F84PEM8JQ50cUgXH2mrKlyq5RniOQ4vVjPLHdu86OKGi2eIr%2BgNV6JwljmYO6zlbJsbWp4hPtVrjYpLLV7UHIp7rOVkixtaniE%2BU5I2Nc2FKJytZhTuiac5rLnh4hniEzUbDjXhn3g5W0nNA1aAKm7YPEN8bMecrZYLWl70hkcyBay5YfMM8aHI4aR7xAUVHyirOdhAmRsqniE%2BtOKsRjIXtDzmmRGHVmDFDRfPEB%2BJzMmO01xScdYnVRs6vPHMFG9W4ZrMM8RHouWw43DNhlDWiSVZY3nDoWYc3qzDNZlniPe6w4uoOFjcKhPXuJNWyG6VqjSuhm7%2BiZorUfEM8U5J8nKyMw0tcZLwPxdRtTlUcUgVdGlml0uZ4pqKZ4hr5VUnpSXdUgVa4hA5vHERV1Tp9XhdJTWHksYd%2Ftdarql4hrjQiaPiYLclNSeebVYz5o0W7Ghsa9blmlFtx01rxP8yy5XIPEP8L1W7bjWHlbzhRTwjzXrCK1f3qqSEyBysLVtayKp40yqurcITxJtUgavVHNob%2FinZTWt5VVvWVKvJSttQCkRjb%2FA4vLK5thOeIN6sm9ai5cTFhYRDy%2FyTGpdU0hxkaZvWUrZluTmLims14QniVbywClqgeouT9IZXNWoupGzNqHa3y5LGVYBnipbCSVxcq1meIN54oRXsbEk26S3NmBcZ807K3gon2ZLcxF5tPMVJprlWE54g3nihtbRHm7WjkbxTHSCWwj1r2U4HSMmdQEmWwonNtah4gnhjA9ZSaohmpnpDjWRptDwS25LcQGsc2Bla5sTFtZV4gnixpWmIVWpgRuVwsiV5q7kv0JJcNVIFapydUrHTQKa5IfMEcRKrurSQ0qhsmVR4kea%2B7pIr9NqSrRltWlaxomUgVVyLxBPEYeUGygtszew2KfOBclVpVN2ctCXNidZaaKWmONhc6rKaJwi6xuGkRmWpAkRa7outF9XN%2F7LlmbJmpiCyvBxk%2FtnSqHmGWGk5i2ZcaWBLau5KKHt3Ce%2FsaLMz46VG4cTFm%2FaMOzxFUYWztjzhkNI43JPyYvPAegPxzFRpOYmWF1WywrPUag5xjRapqqxxubijvYFVaC%2Fv7YSDpzxjzlbhpKXxhqcpWshqtECk0Yys6m5utZdD1LCuCifhfyVOapqsxhyiQMmSm58QNdZheZGV5FqwueXiZBUga28DvRte1NQCpQVSUkFqPbIr%2FIxg7arwJqqEg6e5Vuas1Zytyw1ka5uT9ajKI87WbksaLT8mbkXFyWqaa2rOVuFVStUNpGrDoSTPmDfWdlby8kPiHQtoa0vLpXU4WzX%2FS5W2gWxtOHQ24U3CSUmu8BPinR2XVSFyuNAOZ9Fyae1qDu2qcF8suRKeJt7pcW1zaE9xwcVZq7nWtpeTrQ0PrEeq8CTxnsWrlbThELra5ixqbsXWNoeq6nBft6TlOeK9VnG2lfb4TKOOlpOouKPsWg4pb3Nf1uMGusP3iDtKDaTcgMuWvL1FmZOouCtlbwJs1Yb7SuN2Nd8k7mgvXV4OKWALiGkVJ14eyPqQQG9Vc0dWGnn5LnFPTW1z1gW0OdSyag5aHsvaroVs1YZL2dKMt1nzXeKulas52QLanGy3xq4a87Eu2yHZ2uZNWzPjDbDmu8R9a8m7iQNscbKyy%2BWS%2BUzWtqp7qzpA1jPj8KKK7xIPZG2NVWTTSbpKbs5cfEF6y64qV6ctqcKbdvgm8VhSlnWwJbuaV3LzRb11onFt%2BKcVvkl8one7u3bD%2FzJuXnRt%2BFTXVHOWqubQ4rvEEyI1L1Z2h8%2B0eRHLKiBqvkk8IePmxZq1lk%2B0w0nJUHKIlm8ST8ioeVEFtFwbPhA3h8gcdpZV803iCRkVL7Y42bK2w0NlDqXlpJRV803iGZYrnFRxlqwO3eEuN4dSOGlVme8Sz7C37QZqeZPekl0b3nMBreKsp1bNN4lnWIEtF1Vc6i1bVZtwxQX0NC9UrfBN4hk7zaHLNrey1kgVLljATnO2rmj5JvEMqzlrF%2B%2BFXitcsAArnFkdLd8knrFqPmFzyQq0xUm0tJZvEs8oAR0eix0u1ARSqg70NNHyTeIZUqgZ85gdLlgcMjOSRlBqvkk8wwOSp3moJlyoCYfeKkmBVvgm8YyaUJJ5zOJSTXMWSgus%2BC7xjJpA%2BMiquVATXiUcSuGbxDNqmk%2BUxtW82WmurMI3iWd4wifaHo1rNxx2miul8E3iGTXhc4nH0lQ1O80VK3yTeEYNX5SspbEnXFmFbxLPqGm%2BrsvWFFdK4ZvEM2rCt6RmzCWL7xLP2Anfs2M3Fyy%2BSzyjpvmqDoed5YrFd4ln7DRftHI19BRXSuGbxDN6wtdEqjF4lisS3yWeEYUvWlkDNeZKTfgm8ZFu7mqFr%2FKMYae4lFH4JvGBVLgraghf09uQMZdabr5JfKC2q1zV3IgarOLLPMWllptvEo%2B1e7dkq5ZrLkip%2BKqa4lLk5ZvEY15INay9XIqXVGS%2BqsdcirzclY
D/ContactsSyncAdapter( 9855): getServerDiffs failed
D/ContactsSyncAdapter( 9855): com.google.wireless.gdata2.parser.ParseException: unparsable feed https://www.google.com/m8/feeds/groups/[email protected]/base2_property-android
D/ContactsSyncAdapter( 9855): at com.google.android.syncadapters.contacts.ContactsSyncAdapter.getServerDiffs(ContactsSyncAdapter.java:1228)
D/ContactsSyncAdapter( 9855): at com.google.android.syncadapters.contacts.ContactsSyncAdapter.innerPerformSync(ContactsSyncAdapter.java:298)
D/ContactsSyncAdapter( 9855): at com.google.android.syncadapters.contacts.ContactsSyncAdapter.onPerformLoggedSync(ContactsSyncAdapter.java:176)
D/ContactsSyncAdapter( 9855): at com.google.android.common.LoggingThreadedSyncAdapter.onPerformSync(LoggingThreadedSyncAdapter.java:33)
D/ContactsSyncAdapter( 9855): at android.content.AbstractThreadedSyncAdapter$SyncThread.run(AbstractThreadedSyncAdapter.java:254)
D/ContactsSyncAdapter( 9855): FAILURE: processed 0 records in 300 ms from feed https://www.google.com/m8/feeds/groups/[email protected]/base2_property-android, updated time is 2013-08-28T07:57:30.603Z
The first part is (i think) google doing its sync and everything going ok (but deleting my new contact) so no debug is output. I then entered the contact again and manually did a sync and got the second set of debug, where there is a problem with getting the diff list from the server. After which the contact remained, but only until the contact list managed to sync without error.
Extremely annoying! Anyone know a decent avenue to vent my frustration towards some Google support?

Categories

Resources