[GH-ISSUE #973] [Question] How to add a new option in Profile Builder ? #684

Closed
opened 2026-02-27 15:51:24 +03:00 by kerem · 5 comments
Owner

Originally created by @mehroz1 on GitHub (Jun 2, 2021).
Original GitHub issue: https://github.com/quasar/Quasar/issues/973

Sorry for opening an issue here but I am stuck on this problem for two days. I am trying add to new option to allow client to connect to a website. I have connected the client to website but the link of the website is hard coded in client at the moment. Now I want to add link of the website to profile builder so it can be changed when a new client is generated. The problem is I can't seem to figure out how Quasar\Server\Build\ClientBuilder.cs is injecting values Client.bin and how Quasar\Client\Config\Settings.cs is able to read them.

Here is my ClientBuilder.cs:

Client-Builder

Here is my Settings.cs:
Settings

Can anyone tell me what I am doing wrong here? I am trying to send unencrypted url link to Client.bin but when client is executed i receive an empty string. Any help would be much appreciated.

Originally created by @mehroz1 on GitHub (Jun 2, 2021). Original GitHub issue: https://github.com/quasar/Quasar/issues/973 Sorry for opening an issue here but I am stuck on this problem for two days. I am trying add to new option to allow client to connect to a website. I have connected the client to website but the link of the website is hard coded in client at the moment. Now I want to add link of the website to profile builder so it can be changed when a new client is generated. The problem is I can't seem to figure out how Quasar\Server\Build\ClientBuilder.cs is injecting values Client.bin and how Quasar\Client\Config\Settings.cs is able to read them. Here is my ClientBuilder.cs: ![Client-Builder](https://user-images.githubusercontent.com/9348863/120508138-e959d000-c3e0-11eb-80da-31bf2bc560d1.jpg) Here is my Settings.cs: ![Settings](https://user-images.githubusercontent.com/9348863/120508149-eb239380-c3e0-11eb-8cea-27081e95e821.jpg) Can anyone tell me what I am doing wrong here? I am trying to send unencrypted url link to Client.bin but when client is executed i receive an empty string. Any help would be much appreciated.
kerem 2026-02-27 15:51:24 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@MaxXor commented on GitHub (Jun 2, 2021):

Looks correct. Check out this commit: github.com/quasar/Quasar@053890b933 (diff-0de2da8eed)

In this commit a new option (boolean) was added, but string is almost the same. Hope it does help you.

<!-- gh-comment-id:853339088 --> @MaxXor commented on GitHub (Jun 2, 2021): Looks correct. Check out this commit: https://github.com/quasar/Quasar/commit/053890b9338875d2f75c78c82659bef94b86ed00#diff-0de2da8eed089f3fd8923fb3446ef6caae89c4f02c1355b85490e0d7164ee3f2 In this commit a new option (boolean) was added, but string is almost the same. Hope it does help you.
Author
Owner

@mehroz1 commented on GitHub (Jun 3, 2021):

Thank you

<!-- gh-comment-id:853645828 --> @mehroz1 commented on GitHub (Jun 3, 2021): Thank you
Author
Owner

@mehroz1 commented on GitHub (Jun 3, 2021):

Here is an update
in Quasar\Client\Settings.cs I moved this line
public static string CONTROLDOMAIN = "";
from line 73 to 70 and placed it above install path and log path it started working.

I don't understand how Quasar is mapping variables. I mean I can't see any pattern here. Is there any way I can know for sure that I am not disturbing any other static member?

I thoroughly studied your commit and you were able to add UNATTENDEDMODE without any changes in line order.

<!-- gh-comment-id:853683111 --> @mehroz1 commented on GitHub (Jun 3, 2021): Here is an update in Quasar\Client\Settings.cs I moved this line `public static string CONTROLDOMAIN = "";` from line 73 to 70 and placed it above install path and log path it started working. I don't understand how Quasar is mapping variables. I mean I can't see any pattern here. Is there any way I can know for sure that I am not disturbing any other static member? I thoroughly studied your commit and you were able to add UNATTENDEDMODE without any changes in line order.
Author
Owner

@MaxXor commented on GitHub (Jun 7, 2021):

Glad you got it working. The order of the properties in the Settings.cs file is important. As you can see in the WriteSettings method in your first screenshot it uses the order of the strings/bools/ints in the switch/case statements there too. You can check out the order by viewing the decompiled code in ilSpy/dnSpy. Not sure why you had to move CONTROLDOMAIN above INSTALLPATH as that mixes the settings of the last 3 strings. 🤔

<!-- gh-comment-id:856190555 --> @MaxXor commented on GitHub (Jun 7, 2021): Glad you got it working. The order of the properties in the `Settings.cs` file is important. As you can see in the `WriteSettings` method in your first screenshot it uses the order of the strings/bools/ints in the switch/case statements there too. You can check out the order by viewing the decompiled code in ilSpy/dnSpy. Not sure why you had to move `CONTROLDOMAIN` above `INSTALLPATH` as that mixes the settings of the last 3 strings. :thinking:
Author
Owner

@mehroz1 commented on GitHub (Jun 8, 2021):

@MaxXor Yes it should mix up the string that was my initial preception as this was the case with any other position but the output I was getting via Release & Debug showed that each variable was being assigned correct value ( unless the INSTALLPATH is malfunctioning ). I will still inspect the project with ilSpy.

<!-- gh-comment-id:856759527 --> @mehroz1 commented on GitHub (Jun 8, 2021): @MaxXor Yes it should mix up the string that was my initial preception as this was the case with any other position but the output I was getting via Release & Debug showed that each variable was being assigned correct value ( unless the INSTALLPATH is malfunctioning ). I will still inspect the project with ilSpy.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Quasar#684
No description provided.